Set a higher default for maxDiff

testtools.TestCase.maxDiff is the number of characters
shown when two objects do not match for assertDictEqual,
assertMultiLineEqual, and assertSequenceEqual. The
default is 640 which is too low for comparing most dicts.

Change-Id: I1cb7b12b1a7491637b695abe76207b6db8a65fb5
This commit is contained in:
Alex Meade 2015-01-29 16:06:10 -05:00
parent baf76c5986
commit c15a64bdd1

View File

@ -73,6 +73,13 @@ class BaseTestCase(testtools.TestCase):
def __init__(self, *args, **kwds):
super(BaseTestCase, self).__init__(*args, **kwds)
# This is the number of characters shown when two objects do not
# match for assertDictEqual, assertMultiLineEqual, and
# assertSequenceEqual. The default is 640 which is too
# low for comparing most dicts
self.maxDiff = 10000
# Ensure that the mock.patch.stopall cleanup is registered
# before any setUp() methods have a chance to register other
# things to be cleaned up, so it is called last. This allows