Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.debian.maint.python > #15865 > unrolled thread

Bug#1071715: ITP: pytest-httpx -- Intercept and mock HTTPX requests in pytest

Started byEdward Betts <edward@4angle.com>
First post2024-05-24 08:30 +0200
Last post2024-05-24 08:30 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.debian.maint.python


Contents

  Bug#1071715: ITP: pytest-httpx -- Intercept and mock HTTPX requests in pytest Edward Betts <edward@4angle.com> - 2024-05-24 08:30 +0200

#15865 — Bug#1071715: ITP: pytest-httpx -- Intercept and mock HTTPX requests in pytest

FromEdward Betts <edward@4angle.com>
Date2024-05-24 08:30 +0200
SubjectBug#1071715: ITP: pytest-httpx -- Intercept and mock HTTPX requests in pytest
Message-ID<IHwBb-frF8-1@gated-at.bofh.it>
Package: wnpp
Severity: wishlist
Owner: Edward Betts <edward@4angle.com>
X-Debbugs-Cc: debian-devel@lists.debian.org, debian-python@lists.debian.org

* Package name    : pytest-httpx
  Version         : 0.30.0
  Upstream Author : Colin Bounouar <colin.bounouar.dev@gmail.com>
* URL             : https://github.com/Colin-b/pytest_httpx
* License         : MIT
  Programming Lang: Python
  Description     : Intercept and mock HTTPX requests in pytest

  Provides an `httpx_mock` fixture for the pytest framework. This fixture
  allows you to intercept and mock HTTP requests made using the HTTPX library.
  It supports both synchronous and asynchronous HTTPX requests, enabling you
  to define custom responses, including JSON bodies, headers, status codes,
  and more.
  .
  This library is useful for testing scenarios where making actual network
  calls is not feasible or desired. You can simulate various HTTP responses
  and conditions, ensuring your code handles them correctly. Additionally,
  pytest-httpx supports dynamic responses via callbacks, request verification,
  and partial mocking, allowing specific requests to go through unmocked.

I plan to maintain this package as part of the Python team.

[toc] | [standalone]


Back to top | Article view | linux.debian.maint.python


csiph-web