Skip to content

Commit

Permalink
check for err on file.Write
Browse files Browse the repository at this point in the history
  • Loading branch information
marcoandredinis committed Mar 31, 2022
1 parent 48f1040 commit ef479fb
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion tool/tsh/tshconfig_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,8 @@ func TestLoadConfigEmptyFile(t *testing.T) {
require.NoError(t, err)
defer os.Remove(file.Name())

file.Write([]byte(" "))
_, err = file.Write([]byte(" "))
require.NoError(t, err)

gotConfig, gotErr := loadConfig(file.Name())
require.NoError(t, gotErr)
Expand Down

0 comments on commit ef479fb

Please sign in to comment.