From 41543b564d1d8a4a9f80fdb8ce9429a38553a960 Mon Sep 17 00:00:00 2001 From: Daniel Leong Date: Tue, 1 Sep 2020 21:37:42 -0400 Subject: [PATCH] "Check" the error value of ioutil.WriteFile We could, alternatively, use t.Fatal... this matches the MkdirAll invocation from github_template_test, however... --- pkg/cmd/pr/create/create_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/pkg/cmd/pr/create/create_test.go b/pkg/cmd/pr/create/create_test.go index d6bfb1f76..b947b22a5 100644 --- a/pkg/cmd/pr/create/create_test.go +++ b/pkg/cmd/pr/create/create_test.go @@ -889,7 +889,7 @@ func TestPRCreate_survey_defaults_monocommit_template(t *testing.T) { templateFp := path.Join(tmpdir, ".github/PULL_REQUEST_TEMPLATE.md") _ = os.MkdirAll(path.Dir(templateFp), 0700) - ioutil.WriteFile(templateFp, []byte("... turned to a dead channel"), 0700) + _ = ioutil.WriteFile(templateFp, []byte("... turned to a dead channel"), 0700) cs.Stub("") // git config --get-regexp (determineTrackingBranch) cs.Stub("") // git show-ref --verify (determineTrackingBranch)