pythonPackages.mox3: refactor move to python-modules

This commit is contained in:
Chris Ostrouchov 2018-10-25 20:40:31 -04:00 committed by Frederik Rietdijk
parent 366ca6cd6d
commit 52813e6219
2 changed files with 41 additions and 20 deletions

View File

@ -0,0 +1,40 @@
{ stdenv
, buildPythonPackage
, fetchPypi
, python
, subunit
, testrepository
, testtools
, six
, pbr
, fixtures
, isPy36
}:
buildPythonPackage rec {
pname = "mox3";
version = "0.23.0";
src = fetchPypi {
inherit pname version;
sha256 = "0q26sg0jasday52a7y0cch13l0ssjvr4yqnvswqxsinj1lv5ld88";
};
patchPhase = ''
sed -i 's@python@${python.interpreter}@' .testr.conf
'';
buildInputs = [ subunit testrepository testtools six ];
propagatedBuildInputs = [ pbr fixtures ];
# FAIL: mox3.tests.test_mox.RegexTest.testReprWithFlags
# ValueError: cannot use LOCALE flag with a str pattern
doCheck = !isPy36;
meta = with stdenv.lib; {
description = "Mock object framework for Python";
homepage = https://docs.openstack.org/mox3/latest/;
license = licenses.asl20;
};
}

View File

@ -3061,26 +3061,7 @@ in {
mecab-python3 = callPackage ../development/python-modules/mecab-python3 { };
mox3 = buildPythonPackage rec {
name = "mox3-${version}";
version = "0.23.0";
src = pkgs.fetchurl {
url = "mirror://pypi/m/mox3/${name}.tar.gz";
sha256 = "0q26sg0jasday52a7y0cch13l0ssjvr4yqnvswqxsinj1lv5ld88";
};
patchPhase = ''
sed -i 's@python@${python.interpreter}@' .testr.conf
'';
# FAIL: mox3.tests.test_mox.RegexTest.testReprWithFlags
# ValueError: cannot use LOCALE flag with a str pattern
doCheck = !isPy36;
buildInputs = with self; [ subunit testrepository testtools six ];
propagatedBuildInputs = with self; [ pbr fixtures ];
};
mox3 = callPackage ../development/python-modules/mox3 { };
doc8 = callPackage ../development/python-modules/doc8 { };