summary refs log tree commit diff
path: root/pkgs/development/python-modules/slicedimage
diff options
context:
space:
mode:
authorFabian Affolter <mail@fabian-affolter.ch>2021-02-26 19:31:33 +0100
committerFabian Affolter <mail@fabian-affolter.ch>2021-02-27 09:05:03 +0100
commit953b7ae25575d4ede60d6956b9a1b164fcfdfeb6 (patch)
tree9d6f623d17d5d297b1f7bd2b33b66fcf23cdde89 /pkgs/development/python-modules/slicedimage
parent870dbb751f4d851a3dfb554835a0c2f528386982 (diff)
downloadnixpkgs-953b7ae25575d4ede60d6956b9a1b164fcfdfeb6.tar
nixpkgs-953b7ae25575d4ede60d6956b9a1b164fcfdfeb6.tar.gz
nixpkgs-953b7ae25575d4ede60d6956b9a1b164fcfdfeb6.tar.bz2
nixpkgs-953b7ae25575d4ede60d6956b9a1b164fcfdfeb6.tar.lz
nixpkgs-953b7ae25575d4ede60d6956b9a1b164fcfdfeb6.tar.xz
nixpkgs-953b7ae25575d4ede60d6956b9a1b164fcfdfeb6.tar.zst
nixpkgs-953b7ae25575d4ede60d6956b9a1b164fcfdfeb6.zip
python3Packages.slicedimage: switch to pytestCheckHook
Diffstat (limited to 'pkgs/development/python-modules/slicedimage')
-rw-r--r--pkgs/development/python-modules/slicedimage/default.nix22
1 files changed, 12 insertions, 10 deletions
diff --git a/pkgs/development/python-modules/slicedimage/default.nix b/pkgs/development/python-modules/slicedimage/default.nix
index 08bdc183186..506fad5db48 100644
--- a/pkgs/development/python-modules/slicedimage/default.nix
+++ b/pkgs/development/python-modules/slicedimage/default.nix
@@ -1,6 +1,6 @@
 { lib
 , buildPythonPackage
-, fetchPypi
+, fetchFromGitHub
 , boto3
 , diskcache
 , enum34
@@ -10,7 +10,7 @@
 , requests
 , scikitimage
 , six
-, pytest
+, pytestCheckHook
 , isPy27
 , tifffile
 }:
@@ -19,9 +19,11 @@ buildPythonPackage rec {
   pname = "slicedimage";
   version = "4.1.1";
 
-  src = fetchPypi {
-    inherit pname version;
-    sha256 = "7369f1d7fa09f6c9969625c4b76a8a63d2507a94c6fc257183da1c10261703e9";
+  src = fetchFromGitHub {
+    owner = "spacetx";
+    repo = pname;
+    rev = version;
+    sha256 = "1vpg8varvfx0nj6xscdfm7m118hzsfz7qfzn28r9rsfvrhr0dlcw";
   };
 
   propagatedBuildInputs = [
@@ -36,13 +38,13 @@ buildPythonPackage rec {
   ] ++ lib.optionals isPy27 [ pathlib enum34 ];
 
   checkInputs = [
-    pytest
+    pytestCheckHook
   ];
 
-  # ignore tests which require setup
-  checkPhase = ''
-    pytest --ignore tests/io_
-  '';
+  # Ignore tests which require setup, check again if disabledTestFiles can be used
+  pytestFlagsArray = [ "--ignore tests/io_" ];
+
+  pythonImportsCheck = [ "slicedimage" ];
 
   meta = with lib; {
     description = "Library to access sliced imaging data";