From e46a043ecd9f9ef46d1d44393362bb7016454544 Mon Sep 17 00:00:00 2001 From: Marius Bakke Date: Mon, 12 Dec 2016 00:25:27 +0100 Subject: [PATCH] build-system/python: Make sure 'check' returns failures. * guix/build/python-build-system.scm (check): Wrap 'call-setuppy' in 'if' so that it actually fails when the tests fail. Print informational message when skipped. --- guix/build/python-build-system.scm | 14 +++++++++----- 1 file changed, 9 insertions(+), 5 deletions(-) diff --git a/guix/build/python-build-system.scm b/guix/build/python-build-system.scm index 3f280b0ac0..dd07986b94 100644 --- a/guix/build/python-build-system.scm +++ b/guix/build/python-build-system.scm @@ -137,11 +137,15 @@ (define* (check #:key tests? test-target use-setuptools? #:allow-other-keys) ;; (given with `package_dir`). This will by copied to the output, too, ;; so we need to remove. (let ((before (find-files "build" "\\.egg-info$" #:directories? #t))) - (call-setuppy test-target '() use-setuptools?) - (let* ((after (find-files "build" "\\.egg-info$" #:directories? #t)) - (inter (lset-difference eqv? after before))) - (for-each delete-file-recursively inter))) - #t)) + (if (call-setuppy test-target '() use-setuptools?) + (let* ((after (find-files "build" "\\.egg-info$" #:directories? #t)) + (inter (lset-difference eqv? after before))) + (for-each delete-file-recursively inter) + #t) + #f)) + (begin + (format #t "test suite not run~%") + #t))) (define (get-python-version python) (let* ((version (last (string-split python #\-)))