nixpkgs/pkgs/development/python-modules/pip-tools/default.nix

47 lines
1.5 KiB
Nix
Raw Normal View History

2017-10-25 18:04:35 +00:00
{ stdenv, fetchurl, buildPythonPackage, pip, pytest, click, six, first
, setuptools_scm, git, glibcLocales, mock }:
2017-10-25 18:04:35 +00:00
2017-03-12 18:10:19 +00:00
buildPythonPackage rec {
pname = "pip-tools";
2017-10-25 18:04:35 +00:00
version = "1.10.1";
2017-03-12 18:10:19 +00:00
name = "pip-tools-${version}";
2017-06-25 16:55:07 +00:00
src = fetchurl {
url = "mirror://pypi/p/pip-tools/${name}.tar.gz";
2017-10-25 18:04:35 +00:00
sha256 = "37b85d69ceed97337aeefb3e52e41fe0884a505c874757a5bbaa58d92b533ce0";
2017-03-12 18:10:19 +00:00
};
LC_ALL = "en_US.UTF-8";
checkInputs = [ pytest git glibcLocales mock ];
2017-06-25 16:55:07 +00:00
propagatedBuildInputs = [ pip click six first setuptools_scm ];
2017-03-12 18:10:19 +00:00
disabledTests = stdenv.lib.concatMapStringsSep " and " (s: "not " + s) [
# Depend on network tests:
"test_editable_package_vcs"
"test_generate_hashes_all_platforms"
"test_generate_hashes_without_interfering_with_each_other"
"test_realistic_complex_sub_dependencies"
# Expect specific version of "six":
"test_editable_package"
"test_input_file_without_extension"
];
2017-03-12 18:10:19 +00:00
checkPhase = ''
export HOME=$(mktemp -d) VIRTUAL_ENV=1
tests_without_network_access="
not test_realistic_complex_sub_dependencies
and not test_editable_package_vcs
and not test_generate_hashes_all_platforms
and not test_generate_hashes_without_interfering_with_each_other
"
py.test -k "${disabledTests}"
2017-03-12 18:10:19 +00:00
'';
meta = with stdenv.lib; {
description = "Keeps your pinned dependencies fresh";
homepage = https://github.com/jazzband/pip-tools/;
license = licenses.bsd3;
maintainers = with maintainers; [ zimbatm ];
};
}