]> Cypherpunks repositories - gostls13.git/commitdiff
testing: add missing newlines to error messages
authorIan Lance Taylor <iant@golang.org>
Wed, 4 Jan 2017 18:13:18 +0000 (10:13 -0800)
committerIan Lance Taylor <iant@golang.org>
Wed, 4 Jan 2017 20:54:33 +0000 (20:54 +0000)
No test because in practice these errors never occur.

Change-Id: I11c77893ae931fc621c98920cba656790d18ed93
Reviewed-on: https://go-review.googlesource.com/34811
Run-TryBot: Ian Lance Taylor <iant@golang.org>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org>
src/testing/testing.go

index 8fb6d8373e595cfeee1186c7ad4d0549f1f27acf..c972b2737f28d80692e2e8a18f27a7fc53350615 100644 (file)
@@ -895,11 +895,11 @@ func (m *M) before() {
        if *cpuProfile != "" {
                f, err := os.Create(toOutputDir(*cpuProfile))
                if err != nil {
-                       fmt.Fprintf(os.Stderr, "testing: %s", err)
+                       fmt.Fprintf(os.Stderr, "testing: %s\n", err)
                        return
                }
                if err := m.deps.StartCPUProfile(f); err != nil {
-                       fmt.Fprintf(os.Stderr, "testing: can't start cpu profile: %s", err)
+                       fmt.Fprintf(os.Stderr, "testing: can't start cpu profile: %s\n", err)
                        f.Close()
                        return
                }
@@ -908,11 +908,11 @@ func (m *M) before() {
        if *traceFile != "" {
                f, err := os.Create(toOutputDir(*traceFile))
                if err != nil {
-                       fmt.Fprintf(os.Stderr, "testing: %s", err)
+                       fmt.Fprintf(os.Stderr, "testing: %s\n", err)
                        return
                }
                if err := trace.Start(f); err != nil {
-                       fmt.Fprintf(os.Stderr, "testing: can't start tracing: %s", err)
+                       fmt.Fprintf(os.Stderr, "testing: can't start tracing: %s\n", err)
                        f.Close()
                        return
                }