mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-12-14 01:33:10 +00:00
5035d7b650
Previously the pytestCheckHook had no meaning, since the tests were always executed using by other means. Extracting the tests into a dedicated package has become the standard way to escape infinite recursion issues and offers a cleaner approach here.
27 lines
375 B
Nix
27 lines
375 B
Nix
{ buildPythonPackage
|
|
, sanic
|
|
, sanic-testing
|
|
, pytest-asyncio
|
|
, pytestCheckHook
|
|
}:
|
|
|
|
buildPythonPackage {
|
|
pname = "sanic-testing-tests";
|
|
inherit (sanic-testing) version;
|
|
|
|
src = sanic-testing.testsout;
|
|
|
|
dontBuild = true;
|
|
dontInstall = true;
|
|
|
|
checkInputs = [
|
|
pytest-asyncio
|
|
pytestCheckHook
|
|
sanic
|
|
];
|
|
|
|
pythonImportsCheck = [
|
|
"sanic_testing"
|
|
];
|
|
}
|