diff --git a/lostplaces/lostplaces_app/tests/__init__.py b/lostplaces/lostplaces_app/tests/__init__.py index 4d80975..498b38b 100644 --- a/lostplaces/lostplaces_app/tests/__init__.py +++ b/lostplaces/lostplaces_app/tests/__init__.py @@ -1,6 +1,7 @@ -from django.db import models +from django.db import models as django_models from lostplaces_app.models import Explorer + def mock_user(): explorer_list = Explorer.objects.all() if len(explorer_list) <= 0: @@ -17,14 +18,14 @@ class TestSubmittable: def test_submitted_when(self): submitted_when = self.object._meta.get_field('submitted_when') self.assertTrue(submitted_when) - self.assertEqual(type(submitted_when), models.DateTimeField) + self.assertEqual(type(submitted_when), django_models.DateTimeField) self.assertTrue(submitted_when.auto_now_add) def test_submitted_by(self): submitted_by = self.object._meta.get_field('submitted_by') self.assertTrue(submitted_by) - self.assertEqual(type(submitted_by), models.ForeignKey) + self.assertEqual(type(submitted_by), django_models.ForeignKey) self.assertEqual(submitted_by.remote_field.related_name, 'places') self.assertTrue(submitted_by.null) self.assertTrue(submitted_by.blank) - self.assertEqual(submitted_by.remote_field.on_delete, models.SET_NULL) \ No newline at end of file + self.assertEqual(submitted_by.remote_field.on_delete, django_models.SET_NULL) \ No newline at end of file