1{ lib, buildPythonPackage, fetchPypi, isPy3k, pytest, mock, setuptools_scm }:
2
3buildPythonPackage rec {
4 pname = "pytest-mock";
5 version = "1.10.0";
6
7 src = fetchPypi {
8 inherit pname version;
9 sha256 = "d89a8209d722b8307b5e351496830d5cc5e192336003a485443ae9adeb7dd4c0";
10 };
11
12 propagatedBuildInputs = [ pytest ] ++ lib.optional (!isPy3k) mock;
13 nativeBuildInputs = [ setuptools_scm ];
14
15 checkPhase = ''
16 py.test
17 '';
18
19 meta = with lib; {
20 description = "Thin-wrapper around the mock package for easier use with py.test.";
21 homepage = https://github.com/pytest-dev/pytest-mock;
22 license = licenses.mit;
23 maintainers = with maintainers; [ nand0p ];
24 };
25}