Skip to content

Commit 8ca13f1

Browse files
chore: fix lint issues
1 parent 7501ceb commit 8ca13f1

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

internal/cmd/cmd_test.go

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1698,12 +1698,12 @@ func TestDashboardImportCommand(t *testing.T) {
16981698
if err != nil {
16991699
t.Fatalf("failed to create temp file: %v", err)
17001700
}
1701-
defer os.Remove(tmpFile.Name())
1701+
defer func() { _ = os.Remove(tmpFile.Name()) }()
17021702

17031703
if _, err := tmpFile.Write([]byte(dashJSON)); err != nil {
17041704
t.Fatalf("failed to write temp file: %v", err)
17051705
}
1706-
tmpFile.Close()
1706+
_ = tmpFile.Close()
17071707

17081708
oldStdout := os.Stdout
17091709
r, w, _ := os.Pipe()
@@ -1763,12 +1763,12 @@ func TestDashboardImportFallbackCommand(t *testing.T) {
17631763
if err != nil {
17641764
t.Fatalf("failed to create temp file: %v", err)
17651765
}
1766-
defer os.Remove(tmpFile.Name())
1766+
defer func() { _ = os.Remove(tmpFile.Name()) }()
17671767

17681768
if _, err := tmpFile.Write([]byte(dashJSON)); err != nil {
17691769
t.Fatalf("failed to write temp file: %v", err)
17701770
}
1771-
tmpFile.Close()
1771+
_ = tmpFile.Close()
17721772

17731773
oldStdout := os.Stdout
17741774
r, w, _ := os.Pipe()

internal/cmd/profile_test.go

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,7 +44,7 @@ func setupTempConfig(t *testing.T) string {
4444

4545
func teardownTempConfig(t *testing.T, tmpDir string) {
4646
t.Helper()
47-
os.RemoveAll(tmpDir)
47+
_ = os.RemoveAll(tmpDir)
4848
config.ConfigPathOverride = ""
4949
}
5050

@@ -96,7 +96,7 @@ func TestProfileCommands(t *testing.T) {
9696
}
9797

9898
// 4. Add another profile
99-
out, err = executeCommand("profile", "add", "test-prof2", "--host", "test2.looker.com", "--port", "20000")
99+
_, err = executeCommand("profile", "add", "test-prof2", "--host", "test2.looker.com", "--port", "20000")
100100
if err != nil {
101101
t.Fatalf("profile add failed: %v", err)
102102
}

0 commit comments

Comments
 (0)