Add clean up method to OrganizationModelTestCase
This commit is contained in:
@@ -7,12 +7,16 @@ from ..models import Organization
|
||||
from .literals import TEST_ORGANIZATION_LABEL, TEST_ORGANIZATION_EDITED_LABEL
|
||||
|
||||
|
||||
class OrganizationTestCase(TestCase):
|
||||
class OrganizationModelTestCase(TestCase):
|
||||
def setUp(self):
|
||||
self.organization = Organization.objects.create(
|
||||
label=TEST_ORGANIZATION_LABEL
|
||||
)
|
||||
|
||||
def tearDown(self):
|
||||
self.organization.delete()
|
||||
Organization.objects.clear_cache()
|
||||
|
||||
def test_basic(self):
|
||||
queryset = Organization.objects.get_for_now()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user