diff --git a/unittests/test_apiutils.py b/unittests/test_apiutils.py index daa1e1c390ec81cc90c5834b61733b5c9e26925c..e75f60497c92742a4af35fd435bea1c7c078022e 100644 --- a/unittests/test_apiutils.py +++ b/unittests/test_apiutils.py @@ -31,7 +31,7 @@ import tempfile import caosdb as db import caosdb.apiutils from caosdb.apiutils import (apply_to_ids, compare_entities, create_id_query, - resolve_reference, copy_entity, merge_entities) + resolve_reference, merge_entities) from .test_property import testrecord @@ -241,10 +241,11 @@ def test_copy_entities(): r.add_property(name="D", value=[3, 4, 7], importance="OBLIGATORY") r.description = "A fancy test record" - c = copy_entity(r) + c = r.copy() - assert c != r + assert c is not r assert c.name == "A" + assert c.role == r.role assert c.parents[0].name == "B" # Currently parents and properties are always individual to a copy: assert c.parents[0] != r.parents[0]