diff options
Diffstat (limited to 'ishtar_common')
| -rw-r--r-- | ishtar_common/tests.py | 6 | 
1 files changed, 4 insertions, 2 deletions
| diff --git a/ishtar_common/tests.py b/ishtar_common/tests.py index d1e4c54b5..e1fda640c 100644 --- a/ishtar_common/tests.py +++ b/ishtar_common/tests.py @@ -2848,6 +2848,7 @@ class GeoVectorFormTest(TestCase):      fixtures = FILE_FIXTURES      def setUp(self): +        cache.clear()  # TODO: bad cache when doing full test... why?          Operation = apps.get_model("archaeological_operations", "Operation")          self.username, self.password, self.user = create_superuser()          self.ct = ContentType.objects.get_for_model(models.GeoVectorData) @@ -2859,7 +2860,6 @@ class GeoVectorFormTest(TestCase):              "code_patriarche": 99999          }          self.operation = Operation.objects.create(**dct) -          self.origin = models.GeoOriginType.objects.get(              txt_idx="georeferencement",          ) @@ -2931,9 +2931,11 @@ class GeoVectorFormTest(TestCase):                      "geom_type": geom_type                  }              ), data) -        edited_geo = models.GeoVectorData.objects.get( +        q = models.GeoVectorData.objects.filter(              name="Test Geo {}".format(geom_type)          ) +        self.assertEqual(q.count(), 1, msg=_("GeoVectorData not created.")) +        edited_geo = q.all()[0]          self.assertRedirects(response, f"/display/operation/{self.operation.pk}/")          self.assertEqual(edited_geo.name, "Test Geo {}".format(geom_type))          self.assertEqual(edited_geo.origin, self.origin) | 
