Merged revisions 86596 via svnmerge from

svn+ssh://pythondev@svn.python.org/python/branches/py3k

........
  r86596 | ezio.melotti | 2010-11-20 21:04:17 +0200 (Sat, 20 Nov 2010) | 1 line

  #9424: Replace deprecated assert* methods in the Python test suite.
........
This commit is contained in:
Ezio Melotti 2010-11-21 01:30:29 +00:00
parent b65b4937e2
commit 19f2aeba67
164 changed files with 2281 additions and 2279 deletions

View file

@ -881,8 +881,8 @@ class TestCase(object):
self.fail(self._formatMessage(msg, standardMsg))
def assertDictEqual(self, d1, d2, msg=None):
self.assert_(isinstance(d1, dict), 'First argument is not a dictionary')
self.assert_(isinstance(d2, dict), 'Second argument is not a dictionary')
self.assertTrue(isinstance(d1, dict), 'First argument is not a dictionary')
self.assertTrue(isinstance(d2, dict), 'Second argument is not a dictionary')
if d1 != d2:
standardMsg = ('\n' + '\n'.join(difflib.ndiff(
@ -949,9 +949,9 @@ class TestCase(object):
def assertMultiLineEqual(self, first, second, msg=None):
"""Assert that two multi-line strings are equal."""
self.assert_(isinstance(first, str), (
self.assertTrue(isinstance(first, str), (
'First argument is not a string'))
self.assert_(isinstance(second, str), (
self.assertTrue(isinstance(second, str), (
'Second argument is not a string'))
if first != second: