mirror of
https://github.com/coredns/coredns.git
synced 2025-10-28 00:34:24 -04:00
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:
@@ -103,7 +103,7 @@ func TestError(t *testing.T) {
|
||||
// the dnstap error will show only if there is no plugin error
|
||||
_, err := h.ServeDNS(context.TODO(), rw, nil)
|
||||
if err == nil || !strings.HasPrefix(err.Error(), "plugin/dnstap") {
|
||||
t.Fatal("must return the dnstap error but have:", err)
|
||||
t.Fatal("Must return the dnstap error but have:", err)
|
||||
}
|
||||
|
||||
// plugin errors will always overwrite dnstap errors
|
||||
@@ -111,6 +111,6 @@ func TestError(t *testing.T) {
|
||||
h.Next = endWith(0, pluginErr)
|
||||
_, err = h.ServeDNS(context.TODO(), rw, nil)
|
||||
if err != pluginErr {
|
||||
t.Fatal("must return the plugin error but have:", err)
|
||||
t.Fatal("Must return the plugin error but have:", err)
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user