Merge "be more verbose when test fails"
This commit is contained in:
commit
fa43e38d34
@ -185,13 +185,15 @@ class TestResource(BaseVitrageTempest):
|
|||||||
key=lambda resource: resource["vitrage_id"])
|
key=lambda resource: resource["vitrage_id"])
|
||||||
|
|
||||||
self.assertEqual(len(sorted_cli_resources),
|
self.assertEqual(len(sorted_cli_resources),
|
||||||
len(sorted_api_resources))
|
len(sorted_api_resources), 'cli = %s --> api = %s' %
|
||||||
|
(sorted_cli_resources, sorted_api_resources))
|
||||||
|
|
||||||
for cli_resource, api_resource in \
|
for cli_resource, api_resource in \
|
||||||
zip(sorted_cli_resources, sorted_api_resources):
|
zip(sorted_cli_resources, sorted_api_resources):
|
||||||
for item in self.properties:
|
for item in self.properties:
|
||||||
self.assertEqual(cli_resource.get(item).lower(),
|
self.assertEqual(cli_resource.get(item).lower(),
|
||||||
api_resource.get(item).lower())
|
api_resource.get(item).lower(),
|
||||||
|
'for item %s' % item)
|
||||||
|
|
||||||
def _compare_resource_show(self, api_resource_show,
|
def _compare_resource_show(self, api_resource_show,
|
||||||
cli_resource_show):
|
cli_resource_show):
|
||||||
|
Loading…
Reference in New Issue
Block a user