Commit 45e66887 authored by Bryan C. Mills's avatar Bryan C. Mills

cmd/go: remove extraneous 'file' from usage message in script_test

Previously, erroneous usage would produce error messages like:

	FAIL: testdata/script/mod_tidy_replace.txt:4: usage: stdout [-count=N] 'pattern' file

where the “file” argument is not actually valid for the stdout command.

Change-Id: I74100960f4d25da122faa6c82620995a3fbfc75f
Reviewed-on: https://go-review.googlesource.com/c/140858
Run-TryBot: Bryan C. Mills <bcmills@google.com>
TryBot-Result: Gobot Gobot <gobot@golang.org>
Reviewed-by: 's avatarIan Lance Taylor <iant@golang.org>
parent 6c85693b
......@@ -614,7 +614,7 @@ func scriptMatch(ts *testScript, neg bool, args []string, text, name string) {
want = 2
}
if len(args) != want {
ts.fatalf("usage: %s [-count=N] 'pattern' file%s", name, extraUsage)
ts.fatalf("usage: %s [-count=N] 'pattern'%s", name, extraUsage)
}
pattern := args[0]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment