about summary refs log tree commit diff
path: root/nixpkgs/pkgs/development/python-modules/coloredlogs/default.nix
diff options
context:
space:
mode:
Diffstat (limited to 'nixpkgs/pkgs/development/python-modules/coloredlogs/default.nix')
-rw-r--r--nixpkgs/pkgs/development/python-modules/coloredlogs/default.nix31
1 files changed, 23 insertions, 8 deletions
diff --git a/nixpkgs/pkgs/development/python-modules/coloredlogs/default.nix b/nixpkgs/pkgs/development/python-modules/coloredlogs/default.nix
index 8cdd714bf105..0c14ee7b4476 100644
--- a/nixpkgs/pkgs/development/python-modules/coloredlogs/default.nix
+++ b/nixpkgs/pkgs/development/python-modules/coloredlogs/default.nix
@@ -5,14 +5,14 @@
 , humanfriendly
 , verboselogs
 , capturer
-, pytest
+, pytestCheckHook
 , mock
 , util-linux
 }:
 
 buildPythonPackage rec {
   pname = "coloredlogs";
-  version = "15.0";
+  version = "15.0.1";
 
   src = fetchFromGitHub {
     owner = "xolox";
@@ -21,18 +21,33 @@ buildPythonPackage rec {
     sha256 = "sha256-C1Eo+XrrL3bwhT49KyOE6xjbAHJxn9Qy4s1RR5ERVtA=";
   };
 
+  propagatedBuildInputs = [
+    humanfriendly
+  ];
+
+  checkInputs = [
+    pytestCheckHook
+    mock
+    util-linux
+    verboselogs
+    capturer
+  ];
+
   # capturer is broken on darwin / py38, so we skip the test until a fix for
   # https://github.com/xolox/python-capturer/issues/10 is released.
   doCheck = !stdenv.isDarwin;
-  checkPhase = ''
-    PATH=$PATH:$out/bin pytest . -k "not test_plain_text_output_format \
-                                     and not test_auto_install"
+
+  preCheck = ''
+    # Required for the CLI test
+    PATH=$PATH:$out/bin
   '';
-  checkInputs = [ pytest mock util-linux verboselogs capturer ];
 
-  pythonImportsCheck = [ "coloredlogs" ];
+  disabledTests = [
+    "test_plain_text_output_format"
+    "test_auto_install"
+  ];
 
-  propagatedBuildInputs = [ humanfriendly ];
+  pythonImportsCheck = [ "coloredlogs" ];
 
   meta = with lib; {
     description = "Colored stream handler for Python's logging module";