Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix lint errors #7

Merged
merged 1 commit into from
Feb 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@ func TestNewClient(t *testing.T) {
}
}

func TestNewClientWithNilConfig(t *testing.T) { //nolint:paralleltest // t.Setenv is not thread-safe
func TestNewClientWithNilConfig(t *testing.T) {
// Setting environment variables required for NewConfigFromEnv.
t.Setenv("CLOUDCRAFT_PROTOCOL", cloudcraft.DefaultScheme)
t.Setenv("CLOUDCRAFT_HOST", cloudcraft.DefaultHost)
Expand Down
8 changes: 4 additions & 4 deletions internal/xos/env_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ import (
"github.com/DataDog/cloudcraft-go/internal/xos"
)

func TestGetEnv(t *testing.T) { //nolint:paralleltest // Test is not safe to run in parallel.
func TestGetEnv(t *testing.T) {
tests := []struct {
name string
key string
Expand Down Expand Up @@ -43,7 +43,7 @@ func TestGetEnv(t *testing.T) { //nolint:paralleltest // Test is not safe to run
},
}

for _, tt := range tests { //nolint:paralleltest // See above.
for _, tt := range tests { //nolint:paralleltest // Test is not safe to run in parallel.
t.Run(tt.name, func(t *testing.T) {
t.Setenv(tt.key, tt.envVal)
defer os.Unsetenv(tt.key)
Expand All @@ -57,7 +57,7 @@ func TestGetEnv(t *testing.T) { //nolint:paralleltest // Test is not safe to run
}
}

func TestGetDurationEnv(t *testing.T) { //nolint:paralleltest // See above.
func TestGetDurationEnv(t *testing.T) {
tests := []struct {
name string
key string
Expand Down Expand Up @@ -88,7 +88,7 @@ func TestGetDurationEnv(t *testing.T) { //nolint:paralleltest // See above.
},
}

for _, tt := range tests { //nolint:paralleltest // See above.
for _, tt := range tests { //nolint:paralleltest // Test is not safe to run in parallel.
t.Run(tt.name, func(t *testing.T) {
t.Setenv(tt.key, tt.envVal)
defer os.Unsetenv(tt.key)
Expand Down
Loading