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.1.tar.gz
(10.1 kB
view hashes)
Built Distribution
respx-0.10.1-py2.py3-none-any.whl
(18.0 kB
view hashes)
Close
Hashes for respx-0.10.1-py2.py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 43aca802e0fd0c964865b07f101943e7b5902ea070ec94cf8e84a39db8729b06 |
|
MD5 | 919e77a48c75fe6086ac2b8bef679349 |
|
BLAKE2b-256 | 55881a8a5f5f4cf45c8cb80beb57dd6845cd1dce9aa3ff6a3bff3762b61430a1 |