1{
2 lib,
3 buildPythonPackage,
4 fetchFromGitHub,
5 httpx,
6 pytest,
7 pytest-asyncio,
8 pytestCheckHook,
9 pythonOlder,
10 pythonRelaxDepsHook,
11 setuptools,
12 setuptools-scm,
13}:
14
15buildPythonPackage rec {
16 pname = "pytest-httpx";
17 version = "0.30.0";
18 pyproject = true;
19
20 disabled = pythonOlder "3.9";
21
22 src = fetchFromGitHub {
23 owner = "Colin-b";
24 repo = "pytest_httpx";
25 rev = "refs/tags/v${version}";
26 hash = "sha256-JfyqeOCHNHO4IEHVrh47TdWvb8lcy/1Prqnfphs0ufM=";
27 };
28
29 nativeBuildInputs = [
30 pythonRelaxDepsHook
31 setuptools
32 setuptools-scm
33 ];
34
35 buildInputs = [ pytest ];
36
37 propagatedBuildInputs = [ httpx ];
38
39 pythonRelaxDeps = [ "httpx" ];
40
41 nativeCheckInputs = [
42 pytest-asyncio
43 pytestCheckHook
44 ];
45
46 pythonImportsCheck = [ "pytest_httpx" ];
47
48 meta = with lib; {
49 description = "Send responses to httpx";
50 homepage = "https://github.com/Colin-b/pytest_httpx";
51 changelog = "https://github.com/Colin-b/pytest_httpx/blob/v${version}/CHANGELOG.md";
52 license = licenses.mit;
53 maintainers = with maintainers; [ fab ];
54 };
55}