Tests
The tests will be the tricky part, we should ensure some test classes can be reused (the multitenant admin for example), so we move the main test logic to this module and in the other modules we just import the test classes and repeat them there to ensure the integration works correctly, there's an example of this technique in openwisp-controller, which imports the openwisp-users admin tests.
In the case of openwisp-controller, importing the admin tests from openwisp-users was necessary because an integration bug was not spotted during development until it went into production.
DependencyLoaderand relative testsDependencyFinderand relative testsTimeStampedEditableModelTimeReadonlyAdminMixinMultitenantAdminMixinand relative testsMultitenantOrgFilterand relative testsMultitenantObjectFilterand relative testsTests
The tests will be the tricky part, we should ensure some test classes can be reused (the multitenant admin for example), so we move the main test logic to this module and in the other modules we just import the test classes and repeat them there to ensure the integration works correctly, there's an example of this technique in openwisp-controller, which imports the openwisp-users admin tests.
In the case of openwisp-controller, importing the admin tests from openwisp-users was necessary because an integration bug was not spotted during development until it went into production.