mirror of
https://github.com/golang/go
synced 2024-11-24 02:30:12 -07:00
path: fix error message in TestMatch
The message was hardcoded to indicate that the test wanted a nil error, even though in some cases a specific error was wanted. This patch fixes the message to print the wanted error.
This commit is contained in:
parent
5ad0a524d2
commit
c220374845
@ -73,7 +73,7 @@ func TestMatch(t *testing.T) {
|
||||
for _, tt := range matchTests {
|
||||
ok, err := Match(tt.pattern, tt.s)
|
||||
if ok != tt.match || err != tt.err {
|
||||
t.Errorf("Match(%#q, %#q) = %v, %v want %v, nil", tt.pattern, tt.s, ok, err, tt.match)
|
||||
t.Errorf("Match(%#q, %#q) = %v, %v want %v, %v", tt.pattern, tt.s, ok, err, tt.match, tt.err)
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user