From 34e424469590e98b0b19834d0a63833d82e4acc2 Mon Sep 17 00:00:00 2001 From: Anna Shamray Date: Mon, 22 Nov 2021 16:08:57 +0100 Subject: [PATCH] :white_check_mark: update tests with has_geometry field --- src/objecttypes/tests/v1/test_objecttype_api.py | 3 +++ src/objecttypes/tests/v2/test_objecttype_api.py | 1 + 2 files changed, 4 insertions(+) diff --git a/src/objecttypes/tests/v1/test_objecttype_api.py b/src/objecttypes/tests/v1/test_objecttype_api.py index 6645ba37..7081db3f 100644 --- a/src/objecttypes/tests/v1/test_objecttype_api.py +++ b/src/objecttypes/tests/v1/test_objecttype_api.py @@ -42,6 +42,7 @@ def test_get_objecttypes(self): "labels": object_type.labels, "createdAt": "2020-01-01", "modifiedAt": "2020-01-01", + "hasGeometry": object_type.has_geometry, "versions": [ f"http://testserver{reverse('objectversion-detail', args=[object_type.uuid, object_version.version])}" ], @@ -87,6 +88,7 @@ def test_create_objecttype(self): "providerOrganization": "tree provider", "documentationUrl": "http://example.com/doc/trees", "labels": {"key1": "value1"}, + "hasGeometry": False, } response = self.client.post(url, data) @@ -113,6 +115,7 @@ def test_create_objecttype(self): self.assertEqual(object_type.labels, {"key1": "value1"}) self.assertEqual(object_type.created_at, date(2020, 1, 1)) self.assertEqual(object_type.modified_at, date(2020, 1, 1)) + self.assertEqual(object_type.has_geometry, False) def test_update_objecttype(self): object_type = ObjectTypeFactory.create( diff --git a/src/objecttypes/tests/v2/test_objecttype_api.py b/src/objecttypes/tests/v2/test_objecttype_api.py index 6645ba37..6b190045 100644 --- a/src/objecttypes/tests/v2/test_objecttype_api.py +++ b/src/objecttypes/tests/v2/test_objecttype_api.py @@ -42,6 +42,7 @@ def test_get_objecttypes(self): "labels": object_type.labels, "createdAt": "2020-01-01", "modifiedAt": "2020-01-01", + "hasGeometry": object_type.has_geometry, "versions": [ f"http://testserver{reverse('objectversion-detail', args=[object_type.uuid, object_version.version])}" ],