1
0
mirror of https://github.com/kevin1024/vcrpy.git synced 2025-12-08 16:53:23 +00:00
Files
vcrpy/tests/integration/utils.py
Kevin McCarthy cbedb5818a add unit tests
2013-08-11 15:05:39 -10:00

14 lines
334 B
Python

import json
def assert_httpbin_responses_equal(body1, body2):
"""
httpbin.org returns a different `origin` header
each time, so strip this out since it makes testing
difficult.
"""
body1, body2 = json.loads(body1), json.loads(body2)
del body1['origin']
del body2['origin']
assert body1 == body2