From b5853e08979bcbecbf43f320bb99564a4a656160 Mon Sep 17 00:00:00 2001 From: Lars-Dominik Braun Date: Tue, 15 Feb 2022 10:31:24 +0100 Subject: gnu: trash-cli: Use pytest for testing. Running setup.py overwrites the wrappers created by the 'wrap phase. Fixes: * gnu/packages/shellutils.scm (trash-cli)[arguments]: Replace 'check phase with call to pytest. --- gnu/packages/shellutils.scm | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'gnu/packages/shellutils.scm') diff --git a/gnu/packages/shellutils.scm b/gnu/packages/shellutils.scm index 3f9f8a27f4..d0f4068062 100644 --- a/gnu/packages/shellutils.scm +++ b/gnu/packages/shellutils.scm @@ -341,7 +341,14 @@ between various shells or commands.") (mkdir-p bin) (substitute* "setup.py" (("add_script\\('") - (string-append "add_script('" bin "/" ))))))))) + (string-append "add_script('" bin "/" )))))) + ;; Whenever setup.py is invoked, scripts in out/bin/ are + ;; replaced. Thus we cannot invoke setup.py for testing. + ;; Upstream also uses pytest. + (replace 'check + (lambda* (#:key tests? #:allow-other-keys) + (when tests? + (invoke "pytest"))))))) (native-inputs (list python-pytest python-mock -- cgit v1.2.3