Skip to content

Commit

Permalink
Code style from pre-commit.
Browse files Browse the repository at this point in the history
Signed-off-by: Roel van den Berg <roel.vandenberg@kadaster.nl>
  • Loading branch information
RoelvandenBerg committed Dec 7, 2021
1 parent 213ae65 commit 1e0ed94
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 3 deletions.
1 change: 1 addition & 0 deletions util/wait/backoff.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package wait
import (
"fmt"

"k8s.io/apimachinery/pkg/util/runtime"
"k8s.io/apimachinery/pkg/util/wait"
)

Expand Down
2 changes: 1 addition & 1 deletion workflow/artifacts/s3/s3.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ package s3
import (
"context"
"fmt"
envutil "github.com/argoproj/argo-workflows/v3/util/env"
"os"
"time"

Expand All @@ -15,6 +14,7 @@ import (

"github.com/argoproj/argo-workflows/v3/errors"
wfv1 "github.com/argoproj/argo-workflows/v3/pkg/apis/workflow/v1alpha1"
envutil "github.com/argoproj/argo-workflows/v3/util/env"
errorsutil "github.com/argoproj/argo-workflows/v3/util/errors"
waitutil "github.com/argoproj/argo-workflows/v3/util/wait"
artifactscommon "github.com/argoproj/argo-workflows/v3/workflow/artifacts/common"
Expand Down
6 changes: 4 additions & 2 deletions workflow/artifacts/s3/s3_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -239,7 +239,7 @@ func TestLoadS3Artifact(t *testing.T) {
},
}

t.Setenv(transientEnvVarKey, "this error is transient")
_ = os.Setenv(transientEnvVarKey, "this error is transient")
for name, tc := range tests {
t.Run(name, func(t *testing.T) {
success, err := loadS3Artifact(tc.s3client, &wfv1.Artifact{
Expand All @@ -260,6 +260,7 @@ func TestLoadS3Artifact(t *testing.T) {
}
})
}
_ = os.Unsetenv(transientEnvVarKey)
}

func TestSaveS3Artifact(t *testing.T) {
Expand Down Expand Up @@ -372,7 +373,7 @@ func TestSaveS3Artifact(t *testing.T) {
}

for name, tc := range tests {
t.Setenv(transientEnvVarKey, "this error is transient")
_ = os.Setenv(transientEnvVarKey, "this error is transient")
t.Run(name, func(t *testing.T) {
success, err := saveS3Artifact(
tc.s3client,
Expand All @@ -398,5 +399,6 @@ func TestSaveS3Artifact(t *testing.T) {
assert.Equal(t, tc.errMsg, "")
}
})
_ = os.Unsetenv(transientEnvVarKey)
}
}

0 comments on commit 1e0ed94

Please sign in to comment.