nixpkgs/pkgs/development/python-modules/tld/default.nix

40 lines
946 B
Nix
Raw Normal View History

2019-05-01 22:56:49 +01:00
{ stdenv, fetchPypi, python }:
2019-05-01 22:29:34 +01:00
2019-05-01 22:56:49 +01:00
python.pkgs.buildPythonPackage rec {
2019-05-01 22:29:34 +01:00
pname = "tld";
2019-11-11 11:13:41 +00:00
version = "0.9.7";
2019-05-01 22:29:34 +01:00
src = fetchPypi {
inherit pname version;
2019-11-11 11:13:41 +00:00
sha256 = "cef15360ec42547a583d49ef5246936b3ace424a95c00b59c09dcbe44b289961";
2019-05-01 22:29:34 +01:00
};
2019-05-01 22:56:49 +01:00
propagatedBuildInputs = with python.pkgs; [ six ];
checkInputs = with python.pkgs; [ factory_boy faker pytestcov tox pytestCheckHook];
2019-05-01 22:56:49 +01:00
# https://github.com/barseghyanartur/tld/issues/54
disabledTests = [
2019-05-01 22:56:49 +01:00
"test_1_update_tld_names"
"test_1_update_tld_names_command"
"test_2_update_tld_names_module"
];
2019-05-01 22:56:49 +01:00
preCheck = ''
export PATH="$PATH:$out/bin"
2019-05-01 22:56:49 +01:00
'';
2019-05-01 22:29:34 +01:00
dontUseSetuptoolsCheck = true;
pythonImportsCheck = [
"tld"
];
2019-05-01 22:29:34 +01:00
meta = with stdenv.lib; {
homepage = https://github.com/barseghyanartur/tld;
description = "Extracts the top level domain (TLD) from the URL given";
license = licenses.lgpl21;
maintainers = with maintainers; [ genesis ];
};
}