python3Packages.robotframework-tools: fix build

This commit is contained in:
Fabian Affolter 2021-02-15 13:44:46 +01:00
parent 034d652422
commit 6e455fe61e

View file

@ -8,7 +8,7 @@
, six , six
, zetup , zetup
, modeled , modeled
, pytest , pytestCheckHook
}: }:
buildPythonPackage rec { buildPythonPackage rec {
@ -20,9 +20,7 @@ buildPythonPackage rec {
sha256 = "0377ikajf6c3zcy3lc0kh4w9zmlqyplk2c2hb0yyc7h3jnfnya96"; sha256 = "0377ikajf6c3zcy3lc0kh4w9zmlqyplk2c2hb0yyc7h3jnfnya96";
}; };
nativeBuildInputs = [ nativeBuildInputs = [ zetup ];
zetup
];
propagatedBuildInputs = [ propagatedBuildInputs = [
robotframework robotframework
@ -32,19 +30,21 @@ buildPythonPackage rec {
modeled modeled
]; ];
checkInputs = [ postPatch = ''
pytest # Remove upstream's selfmade approach to collect the dependencies
]; # https://github.com/userzimmermann/robotframework-tools/issues/1
substituteInPlace setup.py --replace \
checkPhase = '' "setup_requires=SETUP_REQUIRES + (zfg.SETUP_REQUIRES or [])," ""
# tests require network
pytest test --ignore test/remote/test_remote.py
''; '';
checkInputs = [ pytestCheckHook ];
pytestFlagsArray = [ "test" ];
pythonImportsCheck = [ "robottools" ];
meta = with lib; { meta = with lib; {
description = "Python Tools for Robot Framework and Test Libraries"; description = "Python Tools for Robot Framework and Test Libraries";
homepage = "https://bitbucket.org/userzimmermann/robotframework-tools"; homepage = "https://github.com/userzimmermann/robotframework-tools";
license = licenses.gpl3; license = licenses.gpl3Plus;
maintainers = [ maintainers.costrouc ]; maintainers = [ maintainers.costrouc ];
}; };
} }