2024-06-05 15:53:02 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
buildPythonPackage,
|
|
|
|
fetchPypi,
|
|
|
|
pythonOlder,
|
|
|
|
|
|
|
|
# build-system
|
|
|
|
pbr,
|
|
|
|
setuptools,
|
|
|
|
|
|
|
|
# dependencies
|
|
|
|
aiohttp,
|
|
|
|
|
|
|
|
# tests
|
|
|
|
ddt,
|
|
|
|
pytestCheckHook,
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "aioresponses";
|
2024-01-13 08:15:51 +00:00
|
|
|
version = "0.7.6";
|
|
|
|
pyproject = true;
|
2022-01-13 20:06:32 +00:00
|
|
|
|
2020-04-24 23:36:52 +00:00
|
|
|
disabled = pythonOlder "3.5";
|
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2024-01-13 08:15:51 +00:00
|
|
|
hash = "sha256-95XZ29otYXdIQOfjL1Nm9FdS0a3Bt0yTYq/QFylsfuE=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
nativeBuildInputs = [
|
|
|
|
pbr
|
2024-01-13 08:15:51 +00:00
|
|
|
setuptools
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
propagatedBuildInputs = [ aiohttp ];
|
2024-01-13 08:15:51 +00:00
|
|
|
|
2024-06-05 15:53:02 +00:00
|
|
|
pythonImportsCheck = [ "aioresponses" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2023-02-02 18:25:31 +00:00
|
|
|
nativeCheckInputs = [
|
2020-04-24 23:36:52 +00:00
|
|
|
ddt
|
2021-03-23 19:22:30 +00:00
|
|
|
pytestCheckHook
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTests = [
|
|
|
|
# Skip a test which makes requests to httpbin.org
|
|
|
|
"test_address_as_instance_of_url_combined_with_pass_through"
|
|
|
|
"test_pass_through_with_origin_params"
|
2020-04-24 23:36:52 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
meta = {
|
2024-06-20 14:57:18 +00:00
|
|
|
description = "Helper to mock/fake web requests in python aiohttp package";
|
2020-04-24 23:36:52 +00:00
|
|
|
homepage = "https://github.com/pnuckowski/aioresponses";
|
|
|
|
license = lib.licenses.mit;
|
|
|
|
};
|
|
|
|
}
|