Skip to content

Commit e60dafb

Browse files
committed
Improve test compatibility with legacy httpbin index
Make the tests slightly more flexible to match both the flasgger-based and legacy httpbin index. This is needed for compatibility with psf/httpbin#44 when flasgger is not installed (e.g. on architectures that are not supported by Rust).
1 parent 3ce5979 commit e60dafb

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

tests/integration/test_basic.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -39,7 +39,7 @@ def test_basic_json_use(tmpdir, httpbin):
3939
test_fixture = str(tmpdir.join("synopsis.json"))
4040
with vcr.use_cassette(test_fixture, serializer="json"):
4141
response = urlopen(httpbin.url).read()
42-
assert b"A simple HTTP Request & Response Service." in response
42+
assert b"HTTP Request & Response Service" in response
4343

4444

4545
def test_patched_content(tmpdir, httpbin):

tests/integration/test_register_persister.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,7 @@ def test_load_cassette_with_custom_persister(tmpdir, httpbin):
6666

6767
with my_vcr.use_cassette(test_fixture, serializer="json"):
6868
response = urlopen(httpbin.url).read()
69-
assert b"A simple HTTP Request & Response Service." in response
69+
assert b"HTTP Request & Response Service" in response
7070

7171

7272
def test_load_cassette_persister_exception_handling(tmpdir, httpbin):

0 commit comments

Comments
 (0)