- Move Oscar app configs into Django app config classes
- Rename Oscar/Django apps' app config module
- Remove "oscar.get_core_apps()" and its app overriding
- Remove "oscar.OSCAR_CORE_APPS"
- Port app forking code to work with Django app registry
- Port class loading code to use app configs to get app properties
The idea of splitting integration from unittests is good in theory
but leads to a lot of mental overhead. Besides whenever a tests
interacts with a database it isn't a unittest anyway.
The tests were failing on python 2 due to the fact that the __init__.py
wasn't written so it wasn't a valid module. With this commit we now
also fully leverage pytest functionality to handle temporary paths for
us.
Replace assert statements with appropriate assert* method.
Replace 'assert' with 'assert*' method.
Convert tests.unit.forms.widget_tests to use TestCase class.
Convert bankcard tests to use TestCase.
Convert tests.unit.logging_tests to use TestCase.
This removes all the bits and bobs where we referenced South, or added
some code supporting it. Documentation will be updated in a later
commit, together with other Django changes.
A custom app needs to inherit from Oscar's app config. This ensures the
correct app label, and that any startup code (receivers, etc.) is
executed.
Per the camp ground rule, the fork_app command has been slightly
refactored.
We ship some apps, e.g. search, without models.py. I think that
means it is not a valid Django app for Django < 1.7. But either way,
Django 1.7 definitely allows apps without models.py, so we need to
ensure we do the right thing.
This makes it easier to customise Oscar. You can run this command to
quickly create local versions of an app that you want to customise. The
command creates the appropriate folder, __init__.py and models.py. The
only step requiring human intervention is to modify INSTALLED_APPS to
include the new app package.