python3Packages.pandas: fix tests

Tests now have relative imports to other test files,
so pytest needs to be executed in the
$out/${python.sitePackages}/pandas directory to make
these assumptions valid
wip/yesman
Jonathan Ringer 3 years ago committed by Jonathan Ringer
parent 02f64b7081
commit 3fe3dcd92e
  1. 4
      pkgs/development/python-modules/pandas/default.nix

@ -85,7 +85,6 @@ in buildPythonPackage rec {
doCheck = !stdenv.isAarch64; # upstream doesn't test this architecture
pytestFlagsArray = [
"$out/${python.sitePackages}/pandas"
"--skip-slow"
"--skip-network"
];
@ -120,7 +119,10 @@ in buildPythonPackage rec {
"test_clipboard"
];
# tests have relative paths, and need to reference compiled C extensions
# so change directory where `import .test` is able to be resolved
preCheck = ''
cd $out/${python.sitePackages}/pandas
export LC_ALL="en_US.UTF-8"
PYTHONPATH=$out/${python.sitePackages}:$PYTHONPATH
''

Loading…
Cancel
Save