[Python-checkins] cpython: Use assertEqual rather than assertEquals to avoid the deprecation warning.
gregory.p.smith
python-checkins at python.org
Sun Apr 26 07:06:02 CEST 2015
https://hg.python.org/cpython/rev/8c044904cddb
changeset: 95803:8c044904cddb
user: Gregory P. Smith <greg at krypto.org>
date: Sun Apr 26 05:05:53 2015 +0000
summary:
Use assertEqual rather than assertEquals to avoid the deprecation warning.
files:
Lib/test/test_bytes.py | 8 ++++----
1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/Lib/test/test_bytes.py b/Lib/test/test_bytes.py
--- a/Lib/test/test_bytes.py
+++ b/Lib/test/test_bytes.py
@@ -304,10 +304,10 @@
def test_hex(self):
self.assertRaises(TypeError, self.type2test.hex)
self.assertRaises(TypeError, self.type2test.hex, 1)
- self.assertEquals(self.type2test(b"").hex(), "")
- self.assertEquals(bytearray([0x1a, 0x2b, 0x30]).hex(), '1a2b30')
- self.assertEquals(self.type2test(b"\x1a\x2b\x30").hex(), '1a2b30')
- self.assertEquals(memoryview(b"\x1a\x2b\x30").hex(), '1a2b30')
+ self.assertEqual(self.type2test(b"").hex(), "")
+ self.assertEqual(bytearray([0x1a, 0x2b, 0x30]).hex(), '1a2b30')
+ self.assertEqual(self.type2test(b"\x1a\x2b\x30").hex(), '1a2b30')
+ self.assertEqual(memoryview(b"\x1a\x2b\x30").hex(), '1a2b30')
def test_join(self):
self.assertEqual(self.type2test(b"").join([]), b"")
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list