Clone of https://github.com/NixOS/nixpkgs.git (to stress-test knotserver)
at 19.03 860 B view raw
1{ buildPythonPackage 2, lib 3, six 4, fetchPypi 5, pyyaml 6, mock 7, contextlib2 8, wrapt 9, pytest 10, pytest-httpbin 11, yarl 12, pythonOlder 13, pythonAtLeast 14}: 15 16buildPythonPackage rec { 17 pname = "vcrpy"; 18 version = "2.0.1"; 19 20 src = fetchPypi { 21 inherit pname version; 22 sha256 = "0kws7l3hci1dvjv01nxw3805q9v2mwldw58bgl8s90wqism69gjp"; 23 }; 24 25 checkInputs = [ 26 pytest 27 pytest-httpbin 28 ]; 29 30 propagatedBuildInputs = [ 31 pyyaml 32 wrapt 33 six 34 ] 35 ++ lib.optionals (pythonOlder "3.3") [ contextlib2 mock ] 36 ++ lib.optionals (pythonAtLeast "3.4") [ yarl ]; 37 38 checkPhase = '' 39 py.test --ignore=tests/integration -k "not TestVCRConnection" 40 ''; 41 42 meta = with lib; { 43 description = "Automatically mock your HTTP interactions to simplify and speed up testing"; 44 homepage = https://github.com/kevin1024/vcrpy; 45 license = licenses.mit; 46 }; 47} 48