summaryrefslogtreecommitdiff
path: root/tests/db_functions
diff options
context:
space:
mode:
authorMariusz Felisiak <felisiak.mariusz@gmail.com>2022-04-14 12:12:13 +0200
committerGitHub <noreply@github.com>2022-04-14 12:12:13 +0200
commit1760ad4e8cdbf34a0f38deae300460a0b9c38eac (patch)
tree1815c8c1f40069c434fb38e2487036afd64bece5 /tests/db_functions
parent08f30d1b6ac9b7bc05857f88a70277d5ceb27ba1 (diff)
Relaxed some query ordering assertions in various tests.
It accounts for differences seen on MySQL with MyISAM storage engine.
Diffstat (limited to 'tests/db_functions')
-rw-r--r--tests/db_functions/comparison/test_nullif.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/db_functions/comparison/test_nullif.py b/tests/db_functions/comparison/test_nullif.py
index a65885a3ec..9839e6b4c5 100644
--- a/tests/db_functions/comparison/test_nullif.py
+++ b/tests/db_functions/comparison/test_nullif.py
@@ -18,7 +18,7 @@ class NullIfTests(TestCase):
authors = Author.objects.annotate(nullif=NullIf("alias", "name")).values_list(
"nullif"
)
- self.assertSequenceEqual(
+ self.assertCountEqual(
authors,
[
("smithj",),
@@ -34,7 +34,7 @@ class NullIfTests(TestCase):
authors = Author.objects.annotate(
nullif=NullIf("name", Value(None))
).values_list("nullif")
- self.assertSequenceEqual(authors, [("John Smith",), ("Rhonda",)])
+ self.assertCountEqual(authors, [("John Smith",), ("Rhonda",)])
def test_too_few_args(self):
msg = "'NullIf' takes exactly 2 arguments (1 given)"