From 9e2ff240da9ab1ba1be363dd67e291642d644bef Mon Sep 17 00:00:00 2001 From: Chris Ostrouchov Date: Fri, 12 Apr 2019 09:46:09 -0400 Subject: [PATCH] pythonPackages.pytest-click: init at 0.3 --- .../python-modules/pytest-click/default.nix | 40 +++++++++++++++++++ pkgs/top-level/python-packages.nix | 2 + 2 files changed, 42 insertions(+) create mode 100644 pkgs/development/python-modules/pytest-click/default.nix diff --git a/pkgs/development/python-modules/pytest-click/default.nix b/pkgs/development/python-modules/pytest-click/default.nix new file mode 100644 index 000000000000..e20ebc77ad1d --- /dev/null +++ b/pkgs/development/python-modules/pytest-click/default.nix @@ -0,0 +1,40 @@ +{ lib +, buildPythonPackage +, fetchFromGitHub +, pytest +, click +, pytestcov +, isPy27 +, mock +}: + +buildPythonPackage rec { + pname = "pytest-click"; + version = "0.3"; + + src = fetchFromGitHub { + owner = "Stranger6667"; + repo = "pytest-click"; + rev = version; + sha256 = "1cd15anw8d4rq6qs03j6ag38199rqw7vp0w0w0fm41mvdzr0lwvz"; + }; + + postConfigure = '' + substituteInPlace setup.py \ + --replace "mock==1.0.1" "mock" + ''; + + propagatedBuildInputs = [ + pytest + click + ]; + + checkInputs = [ pytestcov ] ++ lib.optionals isPy27 [ mock ]; + + meta = with lib; { + description = "pytest plugin for click"; + homepage = https://github.com/Stranger6667/pytest-click; + license = licenses.mit; + maintainers = [ maintainers.costrouc ]; + }; +} diff --git a/pkgs/top-level/python-packages.nix b/pkgs/top-level/python-packages.nix index 2a46c332991a..ee0299fefdbf 100644 --- a/pkgs/top-level/python-packages.nix +++ b/pkgs/top-level/python-packages.nix @@ -736,6 +736,8 @@ in { pytesseract = callPackage ../development/python-modules/pytesseract { }; + pytest-click = callPackage ../development/python-modules/pytest-click { }; + pytest-mypy = callPackage ../development/python-modules/pytest-mypy { }; pytest-pylint = callPackage ../development/python-modules/pytest-pylint { };