ansible-later: 2.0.22 -> 2.0.23
[NixPkgs.git] / pkgs / development / python-modules / mock-services / default.nix
blob2917b21dcfe4f7518dcbb3b9db28ef6db4099a63
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , fetchpatch
5 , attrs
6 , funcsigs
7 , requests-mock
8 , pytestCheckHook
9 }:
11 buildPythonPackage rec {
12   pname = "mock-services";
13   version = "0.3.1";
15   src = fetchFromGitHub {
16     owner = "peopledoc";
17     repo = "mock-services";
18     rev = version;
19     sha256 = "1rqyyfwngi1xsd9a81irjxacinkj1zf6nqfvfxhi55ky34x5phf9";
20   };
22   patches = [
23     # Fix issues due to internal API breaking in latest versions of requests-mock
24     (fetchpatch {
25       url = "https://github.com/peopledoc/mock-services/commit/88d3a0c9ef4dd7d5e011068ed2fdbbecc4a1a03a.patch";
26       sha256 = "0a4pwxr33kr525sp8q4mb4cr3n2b51mj2a3052lhg6brdbi4gnms";
27     })
28   ];
30   propagatedBuildInputs = [
31     attrs
32     funcsigs
33     requests-mock
34   ];
36   checkInputs = [
37     pytestCheckHook
38   ];
40   disabledTests = [
41     # require networking
42     "test_real_http_1"
43     "test_restart_http_mock"
44     "test_start_http_mock"
45     "test_stop_http_mock"
46   ];
48   pythonImportsCheck = [ "mock_services" ];
50   meta = with lib; {
51     description = "Mock an entire service API based on requests-mock";
52     homepage = "https://github.com/peopledoc/mock-services";
53     license = licenses.mit;
54     maintainers = with maintainers; [ dotlambda ];
55   };