presubmit: check for uppercase (#1774)

Another thing we can test automatically, we sorta settled on using an
uppercase letter in in t.Log and t.Fatal calls.

Let's just check for this.
This commit is contained in:
Miek Gieben
2018-05-07 22:47:25 +01:00
committed by Yong Tang
parent 15d989e294
commit 643550eabe
25 changed files with 104 additions and 90 deletions

View File

@@ -100,15 +100,15 @@ func TestGroupingServers(t *testing.T) {
groups, err := groupConfigsByListenAddr(test.configs)
if err != nil {
if !test.failing {
t.Fatalf("test %d, expected no errors, but got: %v", i, err)
t.Fatalf("Test %d, expected no errors, but got: %v", i, err)
}
continue
}
if test.failing {
t.Fatalf("test %d, expected to failed but did not, returned values", i)
t.Fatalf("Test %d, expected to failed but did not, returned values", i)
}
if len(groups) != len(test.expectedGroups) {
t.Errorf("test %d : expected the group's size to be %d, was %d", i, len(test.expectedGroups), len(groups))
t.Errorf("Test %d : expected the group's size to be %d, was %d", i, len(test.expectedGroups), len(groups))
continue
}
for _, v := range test.expectedGroups {