From 450ff496e61f0e7509499975dfb3466c77f46dca Mon Sep 17 00:00:00 2001 From: Fabian Affolter Date: Fri, 2 Jul 2021 10:57:42 +0200 Subject: [PATCH] python3Packages.coloredlogs: 15.0 -> 15.0.1 --- .../python-modules/coloredlogs/default.nix | 31 ++++++++++++++----- 1 file changed, 23 insertions(+), 8 deletions(-) diff --git a/pkgs/development/python-modules/coloredlogs/default.nix b/pkgs/development/python-modules/coloredlogs/default.nix index 8cdd714bf105..0c14ee7b4476 100644 --- a/pkgs/development/python-modules/coloredlogs/default.nix +++ b/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,19 +21,34 @@ 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 ]; + + disabledTests = [ + "test_plain_text_output_format" + "test_auto_install" + ]; pythonImportsCheck = [ "coloredlogs" ]; - propagatedBuildInputs = [ humanfriendly ]; - meta = with lib; { description = "Colored stream handler for Python's logging module"; homepage = "https://github.com/xolox/python-coloredlogs";