Clean up outdated references to ContentType

This commit is contained in:
Jeremy Stretch
2024-03-04 10:46:34 -05:00
parent d538010069
commit 0419a69ae8
17 changed files with 51 additions and 63 deletions

View File

@@ -1,6 +1,6 @@
from django.contrib.contenttypes.models import ContentType
from django.test import TestCase
from core.models import ObjectType
from dcim.models import Manufacturer, Site
from tenancy.filtersets import *
from tenancy.models import *
@@ -296,7 +296,7 @@ class ContactAssignmentTestCase(TestCase, ChangeLoggedFilterSetTests):
ContactAssignment.objects.bulk_create(assignments)
def test_object_type(self):
params = {'object_type_id': ContentType.objects.get_by_natural_key('dcim', 'site')}
params = {'object_type_id': ObjectType.objects.get_by_natural_key('dcim', 'site')}
self.assertEqual(self.filterset(params, self.queryset).qs.count(), 3)
def test_contact(self):