]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
binman: Detect skipped tests
authorSimon Glass <sjg@chromium.org>
Mon, 8 Jul 2019 19:18:33 +0000 (13:18 -0600)
committerSimon Glass <sjg@chromium.org>
Wed, 24 Jul 2019 03:27:57 +0000 (20:27 -0700)
If tests are skipped we should ideally exit with an error, since there may
be a missing dependency. However at present this is not desirable since it
breaks travis tests. For now, just report the skips.

Signed-off-by: Simon Glass <sjg@chromium.org>
tools/binman/binman.py

index aad2e9c8bc4224ab303e49e674697689105faf34..9f8c5c99b79c71a7e3c26a55a16fbc8a17b5b8f7 100755 (executable)
@@ -104,9 +104,14 @@ def RunTests(debug, processes, args):
         print(test.id(), err)
     for test, err in result.failures:
         print(err, result.failures)
+    if result.skipped:
+        print('%d binman test%s SKIPPED:' %
+              (len(result.skipped), 's' if len(result.skipped) > 1 else ''))
+        for skip_info in result.skipped:
+            print('%s: %s' % (skip_info[0], skip_info[1]))
     if result.errors or result.failures:
-      print('binman tests FAILED')
-      return 1
+        print('binman tests FAILED')
+        return 1
     return 0
 
 def GetEntryModules(include_testing=True):