nixpkgs mirror (for testing)
github.com/NixOS/nixpkgs
nix
1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5
6 # build-system
7 pbr,
8 setuptools,
9
10 # dependencies
11 aiohttp,
12
13 # tests
14 ddt,
15 pytestCheckHook,
16}:
17
18buildPythonPackage rec {
19 pname = "aioresponses";
20 version = "0.7.8";
21 pyproject = true;
22
23 src = fetchPypi {
24 inherit pname version;
25 hash = "sha256-uGHN/l3FjzuK+sewppc9XXsstgjdD2JT0WuO6Or23xE=";
26 };
27
28 nativeBuildInputs = [
29 pbr
30 setuptools
31 ];
32
33 propagatedBuildInputs = [ aiohttp ];
34
35 pythonImportsCheck = [ "aioresponses" ];
36
37 nativeCheckInputs = [
38 ddt
39 pytestCheckHook
40 ];
41
42 disabledTests = [
43 # Skip tests which make requests to httpbin.org
44 "test_address_as_instance_of_url_combined_with_pass_through"
45 "test_pass_through_with_origin_params"
46 "test_pass_through_unmatched_requests"
47 ];
48
49 meta = {
50 description = "Helper to mock/fake web requests in python aiohttp package";
51 homepage = "https://github.com/pnuckowski/aioresponses";
52 license = lib.licenses.mit;
53 };
54}