stop printing expected error message in fmt command test

This commit is contained in:
Phillip Wittrock
2020-02-13 17:18:46 -08:00
parent a49c9de4a4
commit 1ce469f1fd

View File

@@ -143,6 +143,8 @@ func TestCmd_failFiles(t *testing.T) {
// fmt the files
r := commands.GetFmtRunner("")
r.Command.SetArgs([]string{"notrealfile"})
r.Command.SilenceUsage = true
r.Command.SilenceErrors = true
err := r.Command.Execute()
assert.EqualError(t, err, "lstat notrealfile: no such file or directory")
}