]> granicus.if.org Git - python/commitdiff
Fix use of deprecated assert_ method.
authorGeorg Brandl <georg@python.org>
Mon, 20 Feb 2012 20:37:22 +0000 (21:37 +0100)
committerGeorg Brandl <georg@python.org>
Mon, 20 Feb 2012 20:37:22 +0000 (21:37 +0100)
Lib/test/test_descr.py

index 77cadc01d9f5d708c01d923dde3e26281181ff46..92304b4e7ef51088723e5b91f6b2350d3de28d0b 100644 (file)
@@ -4482,8 +4482,8 @@ class DictProxyTests(unittest.TestCase):
             return '{' + ', '.join(sorted(kvs)) + '}'
         dict_ = {k: v for k, v in self.C.__dict__.items()}
         repr_ = repr(self.C.__dict__)
-        self.assert_(repr_.startswith('dict_proxy('))
-        self.assert_(repr_.endswith(')'))
+        self.assertTrue(repr_.startswith('dict_proxy('))
+        self.assertTrue(repr_.endswith(')'))
         self.assertEqual(sorted_dict_repr(repr_[len('dict_proxy('):-len(')')]),
                          sorted_dict_repr('{!r}'.format(dict_)))