Fix invalid assert states

"self.assertTrue(policies[1].is_deprecated, True)" and
"self.assertTrue(crashy_calls[0], 1)" are not correct, this is
to fix them.

Change-Id: I7b07f0833d675d2939c910f679b54da2b8cda482
This commit is contained in:
zhufl 2019-06-28 16:54:27 +08:00
parent 82169ead1c
commit c46b88ab74
2 changed files with 2 additions and 2 deletions

View File

@ -762,7 +762,7 @@ class TestStoragePolicies(unittest.TestCase):
policies = parse_storage_policies(good_conf)
self.assertEqual(policies.default, policies[0])
self.assertTrue(policies[1].is_deprecated, True)
self.assertTrue(policies[1].is_deprecated)
def test_parse_storage_policies(self):
# ValueError when deprecating policy 0

View File

@ -1414,7 +1414,7 @@ class TestUtils(unittest.TestCase):
# pdb is basically impossible. Sorry about that.
utils.capture_stdio(logger)
logger.info("I like ham")
self.assertTrue(crashy_calls[0], 1)
self.assertGreater(crashy_calls[0], 1)
def test_parse_options(self):
# Get a file that is definitely on disk