Skip to content

Commit 79b9228

Browse files
6543lunny
authored andcommitted
clean
1 parent 54ddf05 commit 79b9228

File tree

2 files changed

+1
-22
lines changed

2 files changed

+1
-22
lines changed

Makefile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,7 @@ test\#%:
385385

386386
.PHONY: coverage
387387
coverage:
388-
GO111MODULE=on $(GO) run -mod=vendor build/gocovmerge.go integration.coverage.out $(shell find . -type f -name "coverage.out") > coverage.all || cat coverage.out
388+
GO111MODULE=on $(GO) run -mod=vendor build/gocovmerge.go integration.coverage.out $(shell find . -type f -name "coverage.out") > coverage.all
389389

390390
.PHONY: unit-test-coverage
391391
unit-test-coverage:

build/gocovmerge.go

Lines changed: 0 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,12 @@
1212
package main
1313

1414
import (
15-
"bufio"
1615
"flag"
1716
"fmt"
1817
"io"
1918
"log"
2019
"os"
2120
"sort"
22-
"strings"
2321

2422
"golang.org/x/tools/cover"
2523
)
@@ -111,25 +109,6 @@ func main() {
111109
for _, file := range flag.Args() {
112110
profiles, err := cover.ParseProfiles(file)
113111
if err != nil {
114-
115-
// for testing only
116-
f, _ := os.Open(file)
117-
defer f.Close()
118-
scanner := bufio.NewScanner(f)
119-
i := 0
120-
lines := []string{}
121-
for scanner.Scan() {
122-
if i > 10 {
123-
break
124-
}
125-
i++
126-
lines = append(lines, scanner.Text())
127-
}
128-
log.Println("=== " + file + " ==============================")
129-
log.Printf("%s\n", strings.Join(lines, "\n"))
130-
log.Println("===============================================")
131-
// end
132-
133112
log.Fatalf("failed to parse profile '%s': %v", file, err)
134113
}
135114
for _, p := range profiles {

0 commit comments

Comments
 (0)