python.pkgs.pathlib2: fix tests

This commit is contained in:
Frederik Rietdijk 2017-12-05 20:21:57 +01:00
parent e60a1fd433
commit 05be27f7dc
2 changed files with 32 additions and 18 deletions

View File

@ -0,0 +1,31 @@
{ lib
, buildPythonPackage
, fetchPypi
, six
, pythonOlder
, scandir
, glibcLocales
}:
if !(pythonOlder "3.4") then null else buildPythonPackage rec {
pname = "pathlib2";
version = "2.2.1";
src = fetchPypi {
inherit pname version;
sha256 = "ce9007df617ef6b7bd8a31cd2089ed0c1fed1f7c23cf2bf1ba140b3dd563175d";
};
propagatedBuildInputs = [ six ] ++ lib.optional (pythonOlder "3.5") scandir;
checkInputs = [ glibcLocales ];
preCheck = ''
export LC_ALL="en_US.UTF-8"
'';
meta = {
description = "This module offers classes representing filesystem paths with semantics appropriate for different operating systems.";
homepage = https://pypi.python.org/pypi/pathlib2/;
license = with lib.licenses; [ mit ];
};
}

View File

@ -14266,24 +14266,7 @@ in {
};
};
pathlib2 = if !(pythonOlder "3.4") then null else buildPythonPackage rec {
name = "pathlib2-${version}";
version = "2.2.1";
src = pkgs.fetchurl {
url = "mirror://pypi/p/pathlib2/${name}.tar.gz";
sha256 = "ce9007df617ef6b7bd8a31cd2089ed0c1fed1f7c23cf2bf1ba140b3dd563175d";
};
propagatedBuildInputs = with self; [ six ] ++ optional (pythonOlder "3.5") scandir;
meta = {
description = "This module offers classes representing filesystem paths with semantics appropriate for different operating systems.";
homepage = https://pypi.python.org/pypi/pathlib2/;
license = with licenses; [ mit ];
};
};
pathlib2 = callPackage ../development/python-modules/pathlib2 { };
pathpy = callPackage ../development/python-modules/path.py { };