def test_same_value_same_id_not_empty_object_property(self): do = self.ctx.DataObject(ident=R.URIRef("http://example.org")) do1 = self.ctx.DataObject(ident=R.URIRef("http://example.org")) dz = self.ctx.DataObject(ident=R.URIRef("http://example.org/vip")) dz1 = self.ctx.DataObject(ident=R.URIRef("http://example.org/vip")) c = DataObject.ObjectProperty("boots", do) c1 = DataObject.ObjectProperty("boots", do1) do.boots(dz) do1.boots(dz1) self.assertEqual(c.identifier, c1.identifier)
def test_object_property_diff_value_insert_order_same_id(self): do = self.ctx.DataObject(ident=R.URIRef("http://example.org")) do1 = self.ctx.DataObject(ident=R.URIRef("http://example.org")) oa = self.ctx.DataObject(ident=R.URIRef("http://example.org/a")) ob = self.ctx.DataObject(ident=R.URIRef("http://example.org/b")) oc = self.ctx.DataObject(ident=R.URIRef("http://example.org/c")) c = DataObject.ObjectProperty("boots", do, multiple=True) c1 = DataObject.ObjectProperty("boots", do1, multiple=True) do.boots(oa) do.boots(ob) do.boots(oc) do1.boots(oc) do1.boots(oa) do1.boots(ob) self.assertEqual(c.identifier, c1.identifier)