about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/pyproj/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/pyproj/default.nix')
-rw-r--r--nixpkgs/pkgs/development/python-modules/pyproj/default.nix33
1 files changed, 18 insertions, 15 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/pyproj/default.nix b/nixpkgs/pkgs/development/python-modules/pyproj/default.nix
index b23cb010f017..c000283e6de8 100644
--- a/nixpkgs/pkgs/development/python-modules/pyproj/default.nix
+++ b/nixpkgs/pkgs/development/python-modules/pyproj/default.nix
@@ -1,7 +1,7 @@
 { lib, buildPythonPackage, fetchFromGitHub, python, pkgs, pythonOlder, isPy27, substituteAll
 , aenum
 , cython
-, pytest
+, pytestCheckHook
 , mock
 , numpy
 , shapely
@@ -34,20 +34,23 @@ buildPythonPackage rec {
     numpy shapely
   ] ++ lib.optional (pythonOlder "3.6") aenum;
 
-  checkInputs = [ pytest mock ];
-
-  # ignore rounding errors, and impure docgen
-  # datadir is ignored because it does the proj look up logic, which isn't relevant
-  checkPhase = ''
-    pytest . -k 'not alternative_grid_name \
-                 and not transform_wgs84_to_alaska \
-                 and not transformer_group__unavailable \
-                 and not transform_group__missing_best \
-                 and not datum \
-                 and not repr' \
-            --ignore=test/test_doctest_wrapper.py \
-            --ignore=test/test_datadir.py
-  '';
+  checkInputs = [ pytestCheckHook mock ];
+
+  # prevent importing local directory
+  preCheck = "cd test";
+  pytestFlagsArray = [
+    "--ignore=test_doctest_wrapper.py"
+    "--ignore=test_datadir.py"
+  ];
+
+  disabledTests = [
+    "alternative_grid_name"
+    "transform_wgs84_to_alaska"
+    "transformer_group__unavailable"
+    "transform_group__missing_best"
+    "datum"
+    "repr"
+  ];
 
   meta = {
     description = "Python interface to PROJ.4 library";