all: replace fmt.Print* calls with t.Log* in tests (#19670)

This commit is contained in:
大彬
2019-07-17 19:20:24 +08:00
committed by Felix Lange
parent 8f80cafa10
commit 4ac04ae0fe
10 changed files with 85 additions and 87 deletions

View File

@ -18,7 +18,6 @@ package main
import (
"encoding/json"
"fmt"
"io/ioutil"
"reflect"
"strings"
@ -61,7 +60,7 @@ func TestAlethSturebyConverter(t *testing.T) {
got := strings.Split(c.Sdump(spec), "\n")
for i := 0; i < len(exp) && i < len(got); i++ {
if exp[i] != got[i] {
fmt.Printf("got: %v\nexp: %v\n", exp[i], got[i])
t.Logf("got: %v\nexp: %v\n", exp[i], got[i])
}
}
}
@ -102,7 +101,7 @@ func TestParitySturebyConverter(t *testing.T) {
got := strings.Split(c.Sdump(spec), "\n")
for i := 0; i < len(exp) && i < len(got); i++ {
if exp[i] != got[i] {
fmt.Printf("got: %v\nexp: %v\n", exp[i], got[i])
t.Logf("got: %v\nexp: %v\n", exp[i], got[i])
}
}
}