Summary: Add a little hack to skip the new Django 1.7 migrations

when running with settings_sqlitetest to speed up the process
 - Legacy-Id: 9076
This commit is contained in:
Ole Laursen 2015-02-12 15:35:05 +00:00
parent b334550d9c
commit a92752bbcf

View file

@ -1,5 +1,6 @@
# Standard settings except we use SQLite, this is useful for speeding
# up tests that depend on the test database, try for instance:
# Standard settings except we use SQLite and skip migrations, this is
# useful for speeding up tests that depend on the test database, try
# for instance:
#
# ./manage.py test --settings=settings_sqlitetest doc.ChangeStateTestCase
#
@ -12,3 +13,12 @@ DATABASES = {
'ENGINE': 'django.db.backends.sqlite3',
},
}
class DisableMigrations(object):
def __contains__(self, item):
return True
def __getitem__(self, item):
return "notmigrations"
MIGRATION_MODULES = DisableMigrations()