diff options
author | Berker Peksag <berker.peksag@gmail.com> | 2014-10-28 12:02:56 +0200 |
---|---|---|
committer | Tim Graham <timograham@gmail.com> | 2014-11-03 11:56:37 -0500 |
commit | f7969b0920c403118656f6bfec58d6454d79ef1a (patch) | |
tree | 866df7de0524251323fef2b4262e672150d95f00 /tests/null_fk_ordering | |
parent | c0c78f1b707f825eee974c65515a837f8cf46e66 (diff) | |
download | django-f7969b0920c403118656f6bfec58d6454d79ef1a.tar.gz |
Fixed #23620 -- Used more specific assertions in the Django test suite.
Diffstat (limited to 'tests/null_fk_ordering')
-rw-r--r-- | tests/null_fk_ordering/tests.py | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/null_fk_ordering/tests.py b/tests/null_fk_ordering/tests.py index ebbd089c36..2fe48f0b19 100644 --- a/tests/null_fk_ordering/tests.py +++ b/tests/null_fk_ordering/tests.py @@ -22,7 +22,7 @@ class NullFkOrderingTests(TestCase): # We can't compare results directly (since different databases sort NULLs to # different ends of the ordering), but we can check that all results are # returned. - self.assertTrue(len(list(Article.objects.all())) == 3) + self.assertEqual(len(list(Article.objects.all())), 3) s = SystemInfo.objects.create(system_name='System Info') f = Forum.objects.create(system_info=s, forum_name='First forum') @@ -39,4 +39,4 @@ class NullFkOrderingTests(TestCase): # everything else, some sort them afterwards. So we extract the ordered list # and check the length. Before the fix, this list was too short (some values # were omitted). - self.assertTrue(len(list(Comment.objects.all())) == 4) + self.assertEqual(len(list(Comment.objects.all())), 4) |