Skip to content

Commit

Permalink
Remove debug log and fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
metal3d committed Apr 19, 2022
1 parent f15d341 commit 7f6cdb4
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 4 deletions.
1 change: 0 additions & 1 deletion cmd/goreorder/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,6 @@ func main() {
}

if filename != "" {
log.Println("PROCESS")
// do not process test files
if strings.HasSuffix(filename, "_test.go") {
log.Fatal("Cannot process test files")
Expand Down
2 changes: 0 additions & 2 deletions ordering/main.go
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,6 @@ import (
"go/parser"
"go/token"
"io/ioutil"
"log"
"os"
"os/exec"
"sort"
Expand Down Expand Up @@ -49,7 +48,6 @@ func Parse(filename, formatCommand string, src interface{}) (map[string][]*GoTyp
sourceCode = src.([]byte)
}
sourceLines := strings.Split(string(sourceCode), "\n")
log.Println(sourceLines)

// Itrerate over all the top level declarations in the file to find "struct" declarations

Expand Down
2 changes: 1 addition & 1 deletion ordering/main_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -109,7 +109,7 @@ func TestReorder(t *testing.T) {
defer teardown(filename)

// reorder the file
content, err := ReorderSource(filename, "gofmt", true)
content, err := ReorderSource(filename, "gofmt", true, nil)
if err != nil {
t.Error(err)
}
Expand Down

0 comments on commit 7f6cdb4

Please sign in to comment.