stig: use pytestCheckHook (#85364)

This commit is contained in:
Julien Moutinho 2020-04-24 05:55:05 +02:00 committed by GitHub
parent 5e6adf78e9
commit 3fe7332383
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -1,9 +1,9 @@
{ lib { lib
, fetchFromGitHub , fetchFromGitHub
, python3 , python3Packages
}: }:
python3.pkgs.buildPythonApplication rec { python3Packages.buildPythonApplication rec {
pname = "stig"; pname = "stig";
# This project has a different concept for pre release / alpha, # This project has a different concept for pre release / alpha,
# Read the project's README for details: https://github.com/rndusr/stig#stig # Read the project's README for details: https://github.com/rndusr/stig#stig
@ -26,7 +26,7 @@ python3.pkgs.buildPythonApplication rec {
--replace "urwidtrees>=1.0.3dev0" "urwidtrees" --replace "urwidtrees>=1.0.3dev0" "urwidtrees"
''; '';
propagatedBuildInputs = with python3.pkgs; [ propagatedBuildInputs = with python3Packages; [
urwid urwid
urwidtrees urwidtrees
aiohttp aiohttp
@ -38,17 +38,23 @@ python3.pkgs.buildPythonApplication rec {
setproctitle setproctitle
]; ];
checkInputs = with python3.pkgs; [ checkInputs = with python3Packages; [
asynctest asynctest
pytest pytestCheckHook
]; ];
# test_string__month_day_hour_minute_second fails on darwin dontUseSetuptoolsCheck = true;
checkPhase = ''
LC_ALL=en_US.utf8 pytest tests \ preCheck = ''
--deselect=tests/client_test/ttypes_test.py::TestTimestamp::test_string__month_day_hour_minute_second export LC_ALL=C
''; '';
pytestFlagsArray = [
"tests"
# test_string__month_day_hour_minute_second fails on darwin
"--deselect=tests/client_test/ttypes_test.py::TestTimestamp::test_string__month_day_hour_minute_second"
];
meta = with lib; { meta = with lib; {
description = "TUI and CLI for the BitTorrent client Transmission"; description = "TUI and CLI for the BitTorrent client Transmission";
homepage = "https://github.com/rndusr/stig"; homepage = "https://github.com/rndusr/stig";