tangled
alpha
login
or
join now
pyrox.dev
/
nixpkgs
0
fork
atom
lol
0
fork
atom
overview
issues
pulls
pipelines
python3Packages.pytest-socket: 0.3.3 -> 0.4.0
Fabian Affolter
4 years ago
72ce588e
c754d40c
+23
-8
1 changed file
expand all
collapse all
unified
split
pkgs
development
python-modules
pytest-socket
default.nix
+23
-8
pkgs/development/python-modules/pytest-socket/default.nix
reviewed
···
1
1
{ lib
2
2
, buildPythonPackage
3
3
, fetchFromGitHub
4
4
+
, fetchpatch
5
5
+
, poetry-core
4
6
, pytest
7
7
+
, pythonOlder
5
8
}:
6
9
7
10
buildPythonPackage rec {
8
11
pname = "pytest-socket";
9
9
-
version = "0.3.3";
12
12
+
version = "0.4.0";
13
13
+
disabled = pythonOlder "3.6";
14
14
+
format = "pyproject";
10
15
11
16
src = fetchFromGitHub {
12
17
owner = "miketheman";
13
18
repo = pname;
14
19
rev = version;
15
15
-
sha256 = "1jbzkyp4xki81h01yl4vg3nrg9b6shsk1ryrmkaslffyhrqnj8zh";
20
20
+
sha256 = "sha256-cFYtJqZ/RjFbn9XlEy6ffxZ2djisajQAwjV/YR2f59Q=";
16
21
};
22
22
+
23
23
+
nativeBuildInputs = [
24
24
+
poetry-core
25
25
+
];
17
26
18
27
buildInputs = [
19
28
pytest
···
23
32
pytest
24
33
];
25
34
26
26
-
checkPhase = ''
27
27
-
pytest
28
28
-
'';
35
35
+
patches = [
36
36
+
# Switch to poetry-core, https://github.com/miketheman/pytest-socket/pull/74
37
37
+
(fetchpatch {
38
38
+
name = "switch-to-poetry-core.patch";
39
39
+
url = "https://github.com/miketheman/pytest-socket/commit/32519170e656e731d24b81770a170333d3efa6a8.patch";
40
40
+
sha256 = "19ksgx77rsa6ijcbml74alwc5052mdqr4rmvqhlzvfcvv3676ig2";
41
41
+
})
42
42
+
];
29
43
30
30
-
# unsurprisingly pytest-socket require network for majority of tests
31
31
-
# to pass...
44
44
+
# pytest-socket require network for majority of tests
32
45
doCheck = false;
46
46
+
47
47
+
pythonImportsCheck = [ "pytest_socket" ];
33
48
34
49
meta = with lib; {
35
50
description = "Pytest Plugin to disable socket calls during tests";
36
51
homepage = "https://github.com/miketheman/pytest-socket";
37
52
license = licenses.mit;
38
38
-
maintainers = [ maintainers.costrouc ];
53
53
+
maintainers = with maintainers; [ costrouc ];
39
54
};
40
55
}