nixpkgs/pkgs/development/python-modules/uvicorn/tests.nix
2023-07-14 14:09:45 +02:00

53 lines
798 B
Nix

{ stdenv
, buildPythonPackage
, asgiref
, uvicorn
, httpx
, pytest-asyncio
, pytestCheckHook
, pytest-mock
, requests
, trustme
, watchgod
, wsproto
}:
buildPythonPackage {
pname = "uvicorn-tests";
inherit (uvicorn) version;
format = "other";
src = uvicorn.testsout;
dontBuild = true;
dontInstall = true;
nativeCheckInputs = [
asgiref
uvicorn
httpx
pytestCheckHook
pytest-asyncio
pytest-mock
requests
trustme
# strictly optional dependencies
watchgod
wsproto
]
++ uvicorn.optional-dependencies.standard;
doCheck = !stdenv.isDarwin;
__darwinAllowLocalNetworking = true;
disabledTests = [
"test_supported_upgrade_request"
"test_invalid_upgrade"
"test_no_server_headers"
"test_multiple_server_header"
];
}