Skip to content

Commit

Permalink
adding error for write file
Browse files Browse the repository at this point in the history
Signed-off-by: Vishwanath Hiremath <[email protected]>
  • Loading branch information
vishwahiremat committed Feb 23, 2024
1 parent fcdc510 commit 8c178ca
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion pkg/recipes/driver/gitconfig_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -128,12 +128,13 @@ func withGlobalGitConfigFile(tmpdir string, content string) func() {

tmpGitConfigFile := filepath.Join(tmpdir, ".gitconfig")

os.WriteFile(
err:=os.WriteFile(
tmpGitConfigFile,
[]byte(content),
0777,
)

require.NoError(t,err)
prevGitConfigEnv := os.Getenv("HOME")
os.Setenv("HOME", tmpdir)

Expand Down

0 comments on commit 8c178ca

Please sign in to comment.