Replace assertEqual([], items) with assertEmpty(items)
Since assertEmpty() function has already been implemented in tempest, let's use this function instead of generic assertEqual() function. This change makes the code and the error messages to be more readable. Therefore it improves maintainability a little bit. Change-Id: I451d5f091f2103dd838da28afca7f3b9fe955d89
This commit is contained in:
parent
b563ed4a06
commit
d4cb471d45
|
@ -1088,7 +1088,7 @@ class TestAlarmDefinitions(base.BaseMonascaTest):
|
|||
self.assertEqual(alarm_definition['match_by'],
|
||||
response_body['match_by'])
|
||||
else:
|
||||
self.assertEqual([], response_body['match_by'])
|
||||
self.assertEmpty(response_body['match_by'])
|
||||
if 'severity' in alarm_definition:
|
||||
self.assertEqual(alarm_definition['severity'],
|
||||
str(response_body['severity']))
|
||||
|
|
Loading…
Reference in New Issue