A utility for mocking out the Python HTTPX library.
Project description
RESPX
A utility for mocking out the Python HTTPX library.
Documentation
Full documentation is available at lundberg.github.io/respx
QuickStart
import httpx
import respx
@respx.mock
def test_something():
request = respx.post("https://foo.bar/baz/", status_code=201)
response = httpx.post("https://foo.bar/baz/")
assert request.called
assert response.status_code == 201
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
respx-0.10.0.tar.gz
(10.1 kB
view hashes)
Built Distribution
respx-0.10.0-py2.py3-none-any.whl
(18.0 kB
view hashes)
Close
Hashes for respx-0.10.0-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 5cdd2581b5105eb01b11260d11315060f135bcad4b2481ada395ee7ade4de5e5 |
|
MD5 | b2b45387bf8196cd5118a62b9aaae3e4 |
|
BLAKE2b-256 | 493c4efdb98c24ba3c561a1bf0da5840ac3038c6c5835d7d74f09451b79d7e73 |