2024-04-21 15:54:59 +00:00
|
|
|
{
|
|
|
|
lib,
|
|
|
|
anyio,
|
|
|
|
buildPythonPackage,
|
2024-09-19 14:19:46 +00:00
|
|
|
curio-compat,
|
2024-04-21 15:54:59 +00:00
|
|
|
fetchFromGitHub,
|
|
|
|
hypothesis,
|
|
|
|
pytest,
|
|
|
|
pytestCheckHook,
|
|
|
|
pythonOlder,
|
|
|
|
poetry-core,
|
|
|
|
trio,
|
|
|
|
trio-asyncio,
|
2024-09-19 14:19:46 +00:00
|
|
|
uvloop,
|
2021-12-19 01:06:50 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "pytest-aio";
|
2024-09-19 14:19:46 +00:00
|
|
|
version = "1.9.0";
|
2024-04-21 15:54:59 +00:00
|
|
|
pyproject = true;
|
2021-12-19 01:06:50 +00:00
|
|
|
|
2024-09-19 14:19:46 +00:00
|
|
|
disabled = pythonOlder "3.9";
|
2021-12-19 01:06:50 +00:00
|
|
|
|
2021-12-30 13:39:12 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "klen";
|
|
|
|
repo = "pytest-aio";
|
2023-04-29 16:46:19 +00:00
|
|
|
rev = "refs/tags/${version}";
|
2024-09-19 14:19:46 +00:00
|
|
|
hash = "sha256-6RxYn8/HAvXv1AEgSIEOLiaBkGgTcqQhWK+xbtxgj/o=";
|
2021-12-19 01:06:50 +00:00
|
|
|
};
|
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
build-system = [ poetry-core ];
|
2021-12-30 13:39:12 +00:00
|
|
|
|
2024-04-21 15:54:59 +00:00
|
|
|
buildInputs = [ pytest ];
|
2021-12-19 01:06:50 +00:00
|
|
|
|
2024-09-19 14:19:46 +00:00
|
|
|
optional-dependencies = {
|
|
|
|
curio = [ curio-compat ];
|
|
|
|
trio = [ trio ];
|
|
|
|
uvloop = [ uvloop ];
|
|
|
|
};
|
|
|
|
|
|
|
|
nativeCheckInputs = [
|
2021-12-30 13:39:12 +00:00
|
|
|
anyio
|
|
|
|
hypothesis
|
2024-09-19 14:19:46 +00:00
|
|
|
pytestCheckHook
|
2021-12-30 13:39:12 +00:00
|
|
|
trio-asyncio
|
2024-09-19 14:19:46 +00:00
|
|
|
] ++ lib.flatten (lib.attrValues optional-dependencies);
|
2024-04-21 15:54:59 +00:00
|
|
|
|
|
|
|
pythonImportsCheck = [ "pytest_aio" ];
|
2021-12-19 01:06:50 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Pytest plugin for aiohttp support";
|
2024-04-21 15:54:59 +00:00
|
|
|
homepage = "https://github.com/klen/pytest-aio";
|
|
|
|
changelog = "https://github.com/klen/pytest-aio/blob/${version}/CHANGELOG.md";
|
2021-12-19 01:06:50 +00:00
|
|
|
license = licenses.mit;
|
|
|
|
maintainers = with maintainers; [ fab ];
|
|
|
|
};
|
|
|
|
}
|