1{ lib
2, isPyPy
3, buildPythonPackage
4, fetchPypi
5
6# build
7, pytest
8
9# runtime
10, setuptools-git
11, mock
12, path
13, execnet
14, termcolor
15, six
16
17# tests
18, cmdline
19, pytestCheckHook
20 }:
21
22buildPythonPackage rec {
23 pname = "pytest-shutil";
24 version = "1.7.0";
25 format = "setuptools";
26
27 src = fetchPypi {
28 inherit pname version;
29 hash = "sha256-2BZSYd5251CFBcNB2UwCsRPclj8nRUOrynTb+r0CEmE=";
30 };
31
32 postPatch = ''
33 substituteInPlace setup.py \
34 --replace "contextlib2" 'contextlib2;python_version<"3"' \
35 --replace "path.py" "path"
36 '';
37
38 buildInputs = [
39 pytest
40 ];
41
42 propagatedBuildInputs = [
43 setuptools-git
44 mock
45 path
46 execnet
47 termcolor
48 six
49 ];
50
51 nativeCheckInputs = [
52 cmdline
53 pytestCheckHook
54 ];
55
56 disabledTests = [
57 "test_pretty_formatter"
58 ] ++ lib.optionals isPyPy [
59 "test_run"
60 "test_run_integration"
61 ];
62
63 meta = with lib; {
64 description = "A goodie-bag of unix shell and environment tools for py.test";
65 homepage = "https://github.com/manahl/pytest-plugins";
66 maintainers = with maintainers; [ ryansydnor ];
67 license = licenses.mit;
68 };
69}