"""This module contains the test cases for the ``broker_models_hooks`` app"""

from django.test.testcases import TestCase

from .broker_models_hooks_testapp.models import (
    ModelWithBrokerHook,
    ModelWithM2M,
    SyncableModelWithBrokerHook,
)


class BaseModelsHooksTestCase(TestCase):
    """Base test case for the ``broker_models_hooks`` discrete app"""

    @classmethod
    def setUpTestData(cls):
        """Create a new ``ModelWithBrokerHook`` and ``ModelWithM2M`` instance"""

        super().setUpTestData()

        cls.model_with_broker_hook = ModelWithBrokerHook.objects.create()
        cls.model_with_m2m = ModelWithM2M.objects.create()
        cls.syncable_model = SyncableModelWithBrokerHook.objects.create()
