pythonPackages.termplotlib: fix build

1. New tests are failing with gnuplot 5.4.2
2. Propagate gnuplot and numpy
This commit is contained in:
Rasmus Précenth
2021-11-19 21:33:47 +01:00
committed by tomberek
parent 42133e8451
commit 8afc4e5436
2 changed files with 47 additions and 5 deletions

View File

@@ -1,4 +1,5 @@
{ lib
, substituteAll
, buildPythonPackage
, fetchFromGitHub
, pytestCheckHook
@@ -19,13 +20,28 @@ buildPythonPackage rec {
};
format = "pyproject";
checkInputs = [ pytestCheckHook numpy exdown gnuplot ];
checkInputs = [
pytestCheckHook
exdown
];
pythonImportsCheck = [ "termplotlib" ];
# there seems to be a newline in the very front of the output
# which causes the test to fail, since it apparently doesn't
# strip whitespace. might be a gnuplot choice? sigh...
disabledTests = [ "test_plot_lim" ];
propagatedBuildInputs = [ numpy ];
patches = [
(substituteAll {
src = ./gnuplot-subprocess.patch;
gnuplot = "${gnuplot.out}/bin/gnuplot";
})
];
# The current gnuplot version renders slightly different test
# graphs, with emphasis on slightly. The plots are still correct.
# Tests pass on gnuplot 5.4.1, but fail on 5.4.2.
disabledTests = [
"test_plot"
"test_nolabel"
];
meta = with lib; {
description = "matplotlib for your terminal";