2020-04-24 23:36:52 +00:00
|
|
|
{ lib
|
|
|
|
, aiohttp
|
2021-01-15 22:18:51 +00:00
|
|
|
, buildPythonPackage
|
|
|
|
, fetchFromGitHub
|
|
|
|
, isPy3k
|
2020-04-24 23:36:52 +00:00
|
|
|
, pytest
|
|
|
|
, pytest-asyncio
|
2021-02-05 17:12:51 +00:00
|
|
|
, pytest-cov
|
2021-01-15 22:18:51 +00:00
|
|
|
, pytestCheckHook
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "aresponses";
|
2021-02-05 17:12:51 +00:00
|
|
|
version = "2.1.4";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2020-09-25 04:45:31 +00:00
|
|
|
disabled = !isPy3k;
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
src = fetchFromGitHub {
|
|
|
|
owner = "CircleUp";
|
|
|
|
repo = pname;
|
|
|
|
rev = version;
|
2021-02-05 17:12:51 +00:00
|
|
|
sha256 = "sha256-crMiMZ2IDuYDFt8Bixg3NRhlUa2tqmfzd7ZeHM+2Iu4=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
aiohttp
|
|
|
|
];
|
|
|
|
|
|
|
|
buildInputs = [
|
|
|
|
pytest
|
|
|
|
pytest-asyncio
|
|
|
|
];
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
checkInputs = [
|
|
|
|
aiohttp
|
|
|
|
pytest-asyncio
|
2021-02-05 17:12:51 +00:00
|
|
|
pytest-cov
|
|
|
|
pytestCheckHook
|
2021-01-15 22:18:51 +00:00
|
|
|
];
|
|
|
|
|
|
|
|
# Disable tests which requires network access
|
|
|
|
disabledTests = [
|
|
|
|
"test_foo"
|
|
|
|
"test_passthrough"
|
|
|
|
];
|
|
|
|
|
2021-02-05 17:12:51 +00:00
|
|
|
__darwinAllowLocalNetworking = true;
|
|
|
|
|
2021-01-15 22:18:51 +00:00
|
|
|
pythonImportsCheck = [ "aresponses" ];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Asyncio testing server";
|
|
|
|
homepage = "https://github.com/circleup/aresponses";
|
|
|
|
license = licenses.mit;
|
2021-01-15 22:18:51 +00:00
|
|
|
maintainers = with maintainers; [ makefu ];
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
}
|