1{ stdenv
2, buildPythonPackage
3, fetchPypi
4, python
5, subunit
6, testrepository
7, testtools
8, six
9, pbr
10, fixtures
11, isPy36
12}:
13
14buildPythonPackage rec {
15 pname = "mox3";
16 version = "0.26.0";
17
18 src = fetchPypi {
19 inherit pname version;
20 sha256 = "b13c0b8459d6fb0688f9a4e70feeec43fa2cca05b727fc01156789596e083bb1";
21 };
22
23 patchPhase = ''
24 sed -i 's@python@${python.interpreter}@' .testr.conf
25 '';
26
27 buildInputs = [ subunit testrepository testtools six ];
28 propagatedBuildInputs = [ pbr fixtures ];
29
30 # FAIL: mox3.tests.test_mox.RegexTest.testReprWithFlags
31 # ValueError: cannot use LOCALE flag with a str pattern
32 doCheck = !isPy36;
33
34 meta = with stdenv.lib; {
35 description = "Mock object framework for Python";
36 homepage = https://docs.openstack.org/mox3/latest/;
37 license = licenses.asl20;
38 };
39
40}