Check against unexpected method call

Unexpected method call was counted but never asserted.

Change-Id: Ice2b7d3bd490ab9bf14450d765151dd234c0e064
This commit is contained in:
Yun Mao
2012-08-07 10:50:44 -04:00
parent 429d39d1dc
commit 45f6c24892

View File

@@ -1930,7 +1930,7 @@ class LibvirtConnTestCase(test.TestCase):
# assert that no exception is raised due to sha1 receiving an int
self.assertEqual(-1, unicode(e).find('must be string or buffer'
', not int'))
count = (0 <= unicode(e).find('Unexpected method call'))
self.assertNotIn('Unexpected method call', unicode(e))
path = os.path.join(FLAGS.instances_path, instance.name)
if os.path.isdir(path):