distutils-r1: fix test runner for setup.py
authorAlexey Sokolov <sokolov@google.com>
Fri, 1 May 2020 09:45:20 +0000 (10:45 +0100)
committerMichał Górny <mgorny@gentoo.org>
Fri, 1 May 2020 10:29:30 +0000 (12:29 +0200)
It didn't fail under nonfatal (e.g. by virtx) if the test failed.

Closes: https://github.com/gentoo/gentoo/pull/15590
Signed-off-by: Michał Górny <mgorny@gentoo.org>
eclass/distutils-r1.eclass

index 51e99a009df187f274ca11f21365a54b38a4445a..254a25fd3a6e3bac8cc7420572ec98ce8e1a4640 100644 (file)
@@ -416,7 +416,8 @@ distutils_enable_tests() {
                        ;;
                setup.py)
                        python_test() {
-                               esetup.py test --verbose
+                               nonfatal esetup.py test --verbose ||
+                                       die "Tests fail with ${EPYTHON}"
                        }
                        ;;
                unittest)