Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
1{ lib 2, buildPythonPackage 3, fetchFromGitHub 4, pytest 5}: 6 7buildPythonPackage rec { 8 pname = "pytest-socket"; 9 version = "0.3.3"; 10 11 src = fetchFromGitHub { 12 owner = "miketheman"; 13 repo = pname; 14 rev = version; 15 sha256 = "1jbzkyp4xki81h01yl4vg3nrg9b6shsk1ryrmkaslffyhrqnj8zh"; 16 }; 17 18 propagatedBuildInputs = [ 19 pytest 20 ]; 21 22 checkInputs = [ 23 pytest 24 ]; 25 26 checkPhase = '' 27 pytest 28 ''; 29 30 # unsurprisingly pytest-socket require network for majority of tests 31 # to pass... 32 doCheck = false; 33 34 meta = with lib; { 35 description = "Pytest Plugin to disable socket calls during tests"; 36 homepage = "https://github.com/miketheman/pytest-socket"; 37 license = licenses.mit; 38 maintainers = [ maintainers.costrouc ]; 39 }; 40}