summaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorAymeric Augustin <aymeric.augustin@m4x.org>2013-12-13 21:29:30 +0100
committerAymeric Augustin <aymeric.augustin@m4x.org>2013-12-17 10:17:45 +0100
commitebda5800aeef3f3158b53aa28b3d503bc972a9a7 (patch)
treeb8ae095d7826ef7f185b2a6e53ecdbe877e64003 /tests
parente85932b54ebc4f03df008accafb2c8acb37361d4 (diff)
Simplified register_models.
Since it's never called with more than one model at a time the current signature is needlessly complicated.
Diffstat (limited to 'tests')
-rw-r--r--tests/migrations/test_commands.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/migrations/test_commands.py b/tests/migrations/test_commands.py
index bad1b307db..a9503e94a8 100644
--- a/tests/migrations/test_commands.py
+++ b/tests/migrations/test_commands.py
@@ -151,7 +151,7 @@ class MakeMigrationsTests(MigrationTestBase):
def test_files_content(self):
self.assertTableNotExists("migrations_unicodemodel")
- app_cache.register_models('migrations', UnicodeModel)
+ app_cache.register_model('migrations', UnicodeModel)
with override_settings(MIGRATION_MODULES={"migrations": self.migration_pkg}):
call_command("makemigrations", "migrations", verbosity=0)
@@ -187,7 +187,7 @@ class MakeMigrationsTests(MigrationTestBase):
def test_failing_migration(self):
#21280 - If a migration fails to serialize, it shouldn't generate an empty file.
- app_cache.register_models('migrations', UnserializableModel)
+ app_cache.register_model('migrations', UnserializableModel)
with six.assertRaisesRegex(self, ValueError, r'Cannot serialize'):
with override_settings(MIGRATION_MODULES={"migrations": self.migration_pkg}):