pythonPackages.htmltreediff: fix build

- add `pythonPackages.nose` as `checkInput` to make the tests passing
- extract expression into its own file

See https://hydra.nixos.org/build/70680974/log
See ticket #36453
This commit is contained in:
Maximilian Bosch 2018-03-11 00:20:17 +01:00
parent 3ab34a01e0
commit 94458721a7
No known key found for this signature in database
GPG Key ID: 091DBF4D1FC46B8E
2 changed files with 27 additions and 24 deletions

View File

@ -0,0 +1,26 @@
{ buildPythonPackage, fetchFromGitHub, isPy3k, lxml, html5lib, nose, stdenv }:
buildPythonPackage rec {
version = "v0.1.2";
pname = "htmltreediff";
disabled = isPy3k;
src = fetchFromGitHub {
owner = "christian-oudard";
repo = pname;
rev = version;
sha256 = "16mqp2jyznrw1mgd3qzybq28h2k5wz7vmmz1m6xpgscazyjhvvd1";
};
propagatedBuildInputs = [ lxml html5lib ];
checkInputs = [ nose ];
meta = with stdenv.lib; {
description = " Structure-aware diff for html and xml documents";
homepage = https://github.com/christian-oudard/htmltreediff;
license = licenses.bsdOriginal;
maintainers = with maintainers; [ ma27 ];
};
}

View File

@ -20547,30 +20547,7 @@ EOF
};
};
htmltreediff = buildPythonPackage rec{
version = "0.1.2";
pname = "htmltreediff";
name = pname + "-${version}";
# Does not work with Py >= 3
disabled = !isPy27;
src = pkgs.fetchFromGitHub {
owner = "christian-oudard";
repo = pname;
rev = "v" + version;
sha256 = "16mqp2jyznrw1mgd3qzybq28h2k5wz7vmmz1m6xpgscazyjhvvd1";
};
propagatedBuildInputs = with self; [ lxml html5lib ];
meta = {
description = " Structure-aware diff for html and xml documents";
homepage = https://github.com/christian-oudard/htmltreediff;
license = licenses.bsdOriginal;
maintainers = with maintainers; [];
};
};
htmltreediff = callPackage ../development/python-modules/htmltreediff { };
repeated_test = buildPythonPackage rec {
name = "repeated_test-${version}";