summaryrefslogtreecommitdiff
path: root/tests/db_functions/math/test_degrees.py
diff options
context:
space:
mode:
authorMariusz Felisiak <felisiak.mariusz@gmail.com>2019-03-15 00:42:01 +0100
committerTim Graham <timograham@gmail.com>2019-03-14 19:42:21 -0400
commitb150d9946013758a2a13eee751ac828d8582d944 (patch)
treecfe35cd257ac0fc64635c57e1c51f74e55085384 /tests/db_functions/math/test_degrees.py
parenta9ce7e2bcd7493ea7bf3ec3f9828b20809ad9884 (diff)
[2.2.x] Simplified test_transform()s in db_functions.math.
Backport of 258110d6cdea5050f8df0bbc9af3fcd9bd342d29 from master.
Diffstat (limited to 'tests/db_functions/math/test_degrees.py')
-rw-r--r--tests/db_functions/math/test_degrees.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/tests/db_functions/math/test_degrees.py b/tests/db_functions/math/test_degrees.py
index a474d276a5..ab687b8da2 100644
--- a/tests/db_functions/math/test_degrees.py
+++ b/tests/db_functions/math/test_degrees.py
@@ -50,5 +50,5 @@ class DegreesTests(TestCase):
with register_lookup(DecimalField, Degrees):
DecimalModel.objects.create(n1=Decimal('5.4'), n2=Decimal('0'))
DecimalModel.objects.create(n1=Decimal('-30'), n2=Decimal('0'))
- objs = DecimalModel.objects.filter(n1__degrees__gt=0)
- self.assertQuerysetEqual(objs, [Decimal('5.4')], lambda a: a.n1)
+ obj = DecimalModel.objects.filter(n1__degrees__gt=0).get()
+ self.assertEqual(obj.n1, Decimal('5.4'))