summaryrefslogtreecommitdiff
path: root/tests/backends
diff options
context:
space:
mode:
authorBerker Peksag <berker.peksag@gmail.com>2014-10-28 12:02:56 +0200
committerTim Graham <timograham@gmail.com>2014-11-03 11:56:37 -0500
commitf7969b0920c403118656f6bfec58d6454d79ef1a (patch)
tree866df7de0524251323fef2b4262e672150d95f00 /tests/backends
parentc0c78f1b707f825eee974c65515a837f8cf46e66 (diff)
Fixed #23620 -- Used more specific assertions in the Django test suite.
Diffstat (limited to 'tests/backends')
-rw-r--r--tests/backends/tests.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/tests/backends/tests.py b/tests/backends/tests.py
index 2ab8f680b5..be876cc089 100644
--- a/tests/backends/tests.py
+++ b/tests/backends/tests.py
@@ -392,7 +392,7 @@ class SequenceResetTest(TestCase):
# If we create a new object now, it should have a PK greater
# than the PK we specified manually.
obj = models.Post.objects.create(name='New post', text='goodbye world')
- self.assertTrue(obj.pk > 10)
+ self.assertGreater(obj.pk, 10)
# This test needs to run outside of a transaction, otherwise closing the
@@ -413,12 +413,12 @@ class ConnectionCreatedSignalTest(TransactionTestCase):
connection_created.connect(receiver)
connection.close()
connection.cursor()
- self.assertTrue(data["connection"].connection is connection.connection)
+ self.assertIs(data["connection"].connection, connection.connection)
connection_created.disconnect(receiver)
data.clear()
connection.cursor()
- self.assertTrue(data == {})
+ self.assertEqual(data, {})
class EscapingChecks(TestCase):