Skip to content

Commit 9797505

Browse files
committed
Fix weird golangci-lint complaint about nil checks
1 parent 40d5c7d commit 9797505

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed

pkg/toolsets/toolsets_test.go

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,14 +4,8 @@ import (
44
"testing"
55
)
66

7-
func TestNewToolsetGroup(t *testing.T) {
7+
func TestNewToolsetGroupIsEmptyWithoutEverythingOn(t *testing.T) {
88
tsg := NewToolsetGroup(false)
9-
if tsg == nil {
10-
t.Fatal("Expected NewToolsetGroup to return a non-nil pointer")
11-
}
12-
if tsg.Toolsets == nil {
13-
t.Fatal("Expected Toolsets map to be initialized")
14-
}
159
if len(tsg.Toolsets) != 0 {
1610
t.Fatalf("Expected Toolsets map to be empty, got %d items", len(tsg.Toolsets))
1711
}

0 commit comments

Comments
 (0)