Add more debug information for JSONResponseHandler
When the expected value doesn't match the received for the JSONResponseHandler, this change adds the received value into the assertion error message.
This commit is contained in:
parent
8a97c3d456
commit
73e284cc63
@ -106,8 +106,8 @@ class JSONResponseHandler(ResponseHandler):
|
||||
raise AssertionError('json path %s cannot match %s' %
|
||||
(path, test.json_data))
|
||||
expected = test.replace_template(value)
|
||||
test.assertEqual(expected, match, 'Unable to match %s as %s'
|
||||
% (path, expected))
|
||||
test.assertEqual(expected, match, 'Unable to match %s as %s, got %s'
|
||||
% (path, expected, match))
|
||||
|
||||
|
||||
class HeadersResponseHandler(ResponseHandler):
|
||||
|
Loading…
x
Reference in New Issue
Block a user