1{
2 lib,
3 buildPythonPackage,
4 fetchPypi,
5 pytest,
6 pytestCheckHook,
7 pexpect,
8}:
9
10buildPythonPackage rec {
11 pname = "pytest-timeout";
12 version = "2.3.1";
13 format = "setuptools";
14
15 src = fetchPypi {
16 inherit pname version;
17 hash = "sha256-Ejl3KRJcbsvaygEDW55SOdTblzUjIK8VWz9d4bpRZdk=";
18 };
19
20 buildInputs = [ pytest ];
21
22 nativeCheckInputs = [
23 pytestCheckHook
24 pexpect
25 ];
26
27 disabledTests = [
28 "test_suppresses_timeout_when_pdb_is_entered"
29 # Remove until https://github.com/pytest-dev/pytest/pull/7207 or similar
30 "test_suppresses_timeout_when_debugger_is_entered"
31 ];
32
33 pytestFlagsArray = [ "-ra" ];
34
35 pythonImportsCheck = [ "pytest_timeout" ];
36
37 meta = with lib; {
38 description = "Pytest plugin to abort hanging tests";
39 homepage = "https://github.com/pytest-dev/pytest-timeout/";
40 changelog = "https://github.com/pytest-dev/pytest-timeout/#changelog";
41 license = licenses.mit;
42 maintainers = with maintainers; [ makefu ];
43 };
44}