Fix Py3 tests using b'' literal
@@ -67,7 +67,7 @@ def test_dont_record_on_exception(tmpdir):
@my_vcr.use_cassette(str(tmpdir.join('dontsave.yml')))
def some_test():
- assert 'Not in content' in urlopen('http://httpbin.org/get')
+ assert b'Not in content' in urlopen('http://httpbin.org/get')
with pytest.raises(AssertionError):
some_test()
@@ -77,6 +77,6 @@ def test_dont_record_on_exception(tmpdir):
# Make sure context decorator has the same behavior
with pytest.raises(AssertionError):
with my_vcr.use_cassette(str(tmpdir.join('dontsave2.yml'))):
- assert 'Not in content' in urlopen('http://httpbin.org/get').read()
+ assert b'Not in content' in urlopen('http://httpbin.org/get').read()
assert not os.path.exists(str(tmpdir.join('dontsave2.yml')))
