| 1 | import osscip-python python python-stdlib 3.11 os/__init__: |
| 2 | import unittestscip-python python python-stdlib 3.11 unittest/__init__: |
| 3 | |
| 4 | import pytestscip-python python pytest 9.0.3 pytest/__init__: |
| 5 | import requestsscip-python python requests 2.32.5 requests/__init__: |
| 6 | |
| 7 | from betamaxscip-python python betamax 0.9.0 betamax/__init__: import Betamax |
| 8 | |
| 9 | |
| 10 | class TestRequests211BodyMatcherscip-python python betamax 0.9.0 `tests.regression.test_requests_2_11_body_matcher`/TestRequests211BodyMatcher#(unittestscip-python python python-stdlib 3.11 unittest/__init__:.TestCasescip-python python betamax 0.9.0 `unittest.case`/TestCase#): |
| 11 | def tearDownscip-python python betamax 0.9.0 `tests.regression.test_requests_2_11_body_matcher`/TestRequests211BodyMatcher#tearDown().(selfscip-python python betamax 0.9.0 `tests.regression.test_requests_2_11_body_matcher`/TestRequests211BodyMatcher#tearDown().(self)): |
| 12 | osscip-python python python-stdlib 3.11 os/__init__:.unlinkscip-python python python-stdlib 3.11 os/unlink().('tests/cassettes/requests_2_11_body_matcher.json') |
| 13 | |
| 14 | @pytestscip-python python pytest 9.0.3 pytest/__init__:.mark.skipif(requestsscip-python python requests 2.32.5 requests/__init__:.__build__scip-python python betamax 0.9.0 builtins/__build__# < 0x020401, |
| 15 | reason="No json keyword.") |
| 16 | def test_requests_with_json_bodyscip-python python betamax 0.9.0 `tests.regression.test_requests_2_11_body_matcher`/TestRequests211BodyMatcher#test_requests_with_json_body().(selfscip-python python betamax 0.9.0 `tests.regression.test_requests_2_11_body_matcher`/TestRequests211BodyMatcher#test_requests_with_json_body().(self)): |
| 17 | s = requestsscip-python python requests 2.32.5 requests/__init__:.Sessionscip-python python betamax 0.9.0 `requests.sessions`/Session#() |
| 18 | with Betamax(s).use_cassette('requests_2_11_body_matcher', |
| 19 | match_requests_on=['body']): |
| 20 | r = s.post('https://httpbin.org/post', json={'a': 2}) |
| 21 | assert r.json() is not None |
| 22 | |
| 23 | s = requestsscip-python python requests 2.32.5 requests/__init__:.Sessionscip-python python betamax 0.9.0 `requests.sessions`/Session#() |
| 24 | with Betamax(s).use_cassette('requests_2_11_body_matcher', |
| 25 | match_requests_on=['body']): |
| 26 | r = s.post('https://httpbin.org/post', json={'a': 2}) |
| 27 | assert r.json() is not None |