Implemented SheerkaOntology
This commit is contained in:
@@ -61,15 +61,15 @@ class TestSheerkaConceptsAlgebra(TestUsingMemoryBasedSheerka):
|
||||
BuiltinConcepts.HASA: {hasa2}, }
|
||||
|
||||
def test_i_can_recognize_myself_when_using_sdp_repository(self):
|
||||
sheerka, context, foo, isa1, hasa1, = self.init_concepts("foo", "isa1", "has1",
|
||||
cache_only=False,
|
||||
create_new=True)
|
||||
sheerka.cache_manager.commit(context)
|
||||
sheerka, context, foo, isa1, hasa1, = self.init_test(cache_only=False). \
|
||||
with_concepts("foo", "isa1", "has1", create_new=True). \
|
||||
unpack()
|
||||
sheerka.om.commit(context)
|
||||
|
||||
new_foo = sheerka.new("foo")
|
||||
sheerka.set_isa(context, new_foo, isa1)
|
||||
sheerka.set_hasa(context, new_foo, hasa1)
|
||||
sheerka.cache_manager.commit(context)
|
||||
sheerka.om.commit(context)
|
||||
|
||||
assert sheerka.recognize(new_foo, all_scores=True) == [ConceptScore(1, new_foo, new_foo)]
|
||||
|
||||
|
||||
Reference in New Issue
Block a user