Merge pull request #307098 from r-ryantm/auto-update/cilium-cli
[NixPkgs.git] / pkgs / development / python-modules / mockfs / default.nix
blob680a6c9fc795bdc51bc5a40c76efc59fda4b4e69
1 { lib
2 , buildPythonPackage
3 , fetchFromGitHub
4 , setuptools
5 , setuptools-scm
6 , importlib-metadata
7 , pytestCheckHook
8 }:
10 buildPythonPackage rec {
11   pname = "mockfs";
12   version = "1.1.4";
13   format = "pyproject";
15   src = fetchFromGitHub {
16     owner = "mockfs";
17     repo = "mockfs";
18     rev = "v${version}";
19     hash = "sha256-JwSkOI0dz9ZetfE0ZL3CthvcCSXGFYX+yQZy/oC6VBk=";
20   };
22   postPatch = ''
23     sed -i '/addopts/d' pytest.ini
24   '';
26   nativeBuildInputs = [
27     setuptools
28     setuptools-scm
29   ];
31   propagatedBuildInputs = [
32     importlib-metadata
33   ];
35   pythonImportsCheck = [ "mockfs" ];
37   nativeCheckInputs = [
38     pytestCheckHook
39   ];
41   meta = with lib; {
42     description = "A simple mock filesystem for use in unit tests";
43     homepage = "https://github.com/mockfs/mockfs";
44     changelog = "https://github.com/mockfs/mockfs/blob/${src.rev}/CHANGES.rst";
45     license = licenses.mit;
46     maintainers = with maintainers; [ ];
47   };