summaryrefslogtreecommitdiff
path: root/tests/invalid_models_tests
diff options
context:
space:
mode:
authorMariusz Felisiak <felisiak.mariusz@gmail.com>2022-02-03 11:20:46 +0100
committerGitHub <noreply@github.com>2022-02-03 11:20:46 +0100
commitc5cd8783825b5f6384417dac5f3889b4210b7d08 (patch)
tree3d4689aaa0e209e40d2d8df09edad7e155960b45 /tests/invalid_models_tests
parentc9d6e3595cfd0aa58cde1656bd735ecfcd7a872b (diff)
downloaddjango-c5cd8783825b5f6384417dac5f3889b4210b7d08.tar.gz
Refs #33476 -- Refactored problematic code before reformatting by Black.
In these cases Black produces unexpected results, e.g. def make_random_password( self, length=10, allowed_chars='abcdefghjkmnpqrstuvwxyz' 'ABCDEFGHJKLMNPQRSTUVWXYZ' '23456789', ): or cursor.execute(""" SELECT ... """, [table name], )
Diffstat (limited to 'tests/invalid_models_tests')
-rw-r--r--tests/invalid_models_tests/test_models.py18
1 files changed, 6 insertions, 12 deletions
diff --git a/tests/invalid_models_tests/test_models.py b/tests/invalid_models_tests/test_models.py
index 4a36ac8285..c8c4cfa420 100644
--- a/tests/invalid_models_tests/test_models.py
+++ b/tests/invalid_models_tests/test_models.py
@@ -1707,8 +1707,7 @@ class ConstraintsTests(TestCase):
self.assertEqual(Model.check(databases=self.databases), [
Error(
- "'constraints' refers to the nonexistent field "
- "'missing_field'.",
+ "'constraints' refers to the nonexistent field 'missing_field'.",
obj=Model,
id='models.E012',
),
@@ -1972,8 +1971,7 @@ class ConstraintsTests(TestCase):
self.assertEqual(Model.check(databases=self.databases), [
Error(
- "'constraints' refers to the nonexistent field "
- "'missing_field'.",
+ "'constraints' refers to the nonexistent field 'missing_field'.",
obj=Model,
id='models.E012',
),
@@ -2075,8 +2073,7 @@ class ConstraintsTests(TestCase):
self.assertEqual(Model.check(databases=self.databases), [
Error(
- "'constraints' refers to the nonexistent field "
- "'missing_field'.",
+ "'constraints' refers to the nonexistent field 'missing_field'.",
obj=Model,
id='models.E012',
),
@@ -2193,8 +2190,7 @@ class ConstraintsTests(TestCase):
self.assertEqual(Model.check(databases=self.databases), [
Error(
- "'constraints' refers to the nonexistent field "
- "'missing_field'.",
+ "'constraints' refers to the nonexistent field 'missing_field'.",
obj=Model,
id='models.E012',
),
@@ -2331,8 +2327,7 @@ class ConstraintsTests(TestCase):
self.assertEqual(Model.check(databases=self.databases), [
Error(
- "'constraints' refers to the nonexistent field "
- "'missing_field'.",
+ "'constraints' refers to the nonexistent field 'missing_field'.",
obj=Model,
id='models.E012',
),
@@ -2348,8 +2343,7 @@ class ConstraintsTests(TestCase):
self.assertEqual(Model.check(databases=self.databases), [
Error(
- "'constraints' refers to the nonexistent field "
- "'missing_field'.",
+ "'constraints' refers to the nonexistent field 'missing_field'.",
obj=Model,
id='models.E012',
),