croc: 10.1.1 -> 10.1.3 (#364662)
[NixPkgs.git] / pkgs / development / python-modules / ipykernel / tests.nix
blob89ac0be2d3d60797480bb8cc2afc14de42599de9
2   lib,
3   stdenv,
4   buildPythonPackage,
5   pythonOlder,
6   flaky,
7   ipykernel,
8   ipyparallel,
9   pre-commit,
10   pytestCheckHook,
11   pytest-asyncio,
12   pytest-timeout,
15 buildPythonPackage {
16   pname = "ipykernel-tests";
17   inherit (ipykernel) version src;
18   format = "other";
20   dontBuild = true;
21   dontInstall = true;
23   nativeCheckInputs = [
24     flaky
25     ipykernel
26     ipyparallel
27     pre-commit
28     pytestCheckHook
29     pytest-asyncio
30     pytest-timeout
31   ];
33   preCheck = ''
34     export HOME=$(mktemp -d)
35   '';
37   disabledTests =
38     [
39       # The follwing three tests fail for unclear reasons.
40       # pytest.PytestUnhandledThreadExceptionWarning: Exception in thread Thread-8
41       "test_asyncio_interrupt"
43       # DeprecationWarning: Passing unrecognized arguments to super(IPythonKernel)
44       "test_embed_kernel_func"
46       # traitlets.config.configurable.MultipleInstanceError: An incompatible siblin...
47       "test_install_kernelspec"
48     ]
49     ++ lib.optionals stdenv.hostPlatform.isDarwin (
50       [
51         # see https://github.com/NixOS/nixpkgs/issues/76197
52         "test_subprocess_print"
53         "test_subprocess_error"
54         "test_ipython_start_kernel_no_userns"
56         # https://github.com/ipython/ipykernel/issues/506
57         "test_unc_paths"
58       ]
59       ++ lib.optionals (pythonOlder "3.8") [
60         # flaky test https://github.com/ipython/ipykernel/issues/485
61         "test_shutdown"
63         # test regression https://github.com/ipython/ipykernel/issues/486
64         "test_sys_path_profile_dir"
65         "test_save_history"
66         "test_help_output"
67         "test_write_kernel_spec"
68         "test_ipython_start_kernel_userns"
69         "ZMQDisplayPublisherTests"
70       ]
71     );
73   # Some of the tests use localhost networking.
74   __darwinAllowLocalNetworking = true;