Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/boringssl.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/util
diff options
context:
space:
mode:
authorDavid Benjamin <davidben@chromium.org>2015-04-05 00:02:18 +0300
committerAdam Langley <agl@google.com>2015-04-06 23:49:54 +0300
commit2ab7a868adce20724698c0b6eaf66fe3a3550149 (patch)
tree8304972f3ec279c5d0bdc1d31ddd748ae69eec72 /util
parentf8ba2855354cf8a6b5a4664a1c93be889b8e2890 (diff)
runner and all_tests should exit with failure on failing tests.
Otherwise the bots don't notice. BUG=473924 Change-Id: Idb8cc4c255723ebbe2d52478040a70648910bf37 Reviewed-on: https://boringssl-review.googlesource.com/4232 Reviewed-by: Adam Langley <agl@google.com>
Diffstat (limited to 'util')
-rw-r--r--util/all_tests.go17
1 files changed, 9 insertions, 8 deletions
diff --git a/util/all_tests.go b/util/all_tests.go
index 1a0651a2..785e4230 100644
--- a/util/all_tests.go
+++ b/util/all_tests.go
@@ -219,18 +219,19 @@ func main() {
}
}
- if len(failed) == 0 {
- fmt.Printf("\nAll tests passed!\n")
- } else {
+ if *jsonOutput != "" {
+ if err := testOutput.writeTo(*jsonOutput); err != nil {
+ fmt.Fprintf(os.Stderr, "Error: %s\n", err)
+ }
+ }
+
+ if len(failed) > 0 {
fmt.Printf("\n%d of %d tests failed:\n", len(failed), len(tests))
for _, test := range failed {
fmt.Printf("\t%s\n", strings.Join([]string(test), " "))
}
+ os.Exit(1)
}
- if *jsonOutput != "" {
- if err := testOutput.writeTo(*jsonOutput); err != nil {
- fmt.Fprintf(os.Stderr, "Error: %s\n", err)
- }
- }
+ fmt.Printf("\nAll tests passed!\n")
}