mirror of
https://github.com/kevin1024/vcrpy.git
synced 2025-12-08 16:53:23 +00:00
Adding json serializer
This commit is contained in:
committed by
Kevin McCarthy
parent
3e247a2efb
commit
51f0f1bacd
@@ -37,3 +37,9 @@ def test_basic_use(tmpdir):
|
||||
with vcr.use_cassette('fixtures/vcr_cassettes/synopsis.yaml'):
|
||||
response = urllib2.urlopen('http://www.iana.org/domains/reserved').read()
|
||||
assert 'Example domains' in response
|
||||
|
||||
def test_basic_json_use(tmpdir):
|
||||
'''Ensure you can load a json serialized cassette'''
|
||||
with vcr.use_cassette('fixtures/vcr_cassettes/synopsis.json', serializer='json'):
|
||||
response = urllib2.urlopen('http://www.iana.org/domains/reserved').read()
|
||||
assert 'Example domains' in response
|
||||
|
||||
Reference in New Issue
Block a user