Skip to content

Commit

Permalink
Merge pull request #138 from reetasingh/fix/validateargs
Browse files Browse the repository at this point in the history
chore: Remove unneeded params passed to common.ValidateArgs function
  • Loading branch information
k8s-ci-robot committed Jan 29, 2024
2 parents 993028e + 6d4a3f0 commit 14110a7
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion cmd/root.go
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ var rootCmd = &cobra.Command{
} else if listImages {
service.PrintListImages(client.ClientSet)
} else {
common.ValidateArgs(client.ClientSet, config)
common.ValidateArgs()

service.RunE2E(client.ClientSet)
client.PrintE2ELogs()
Expand Down
2 changes: 1 addition & 1 deletion pkg/common/args.go
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ func PrintInfo(clientSet *kubernetes.Clientset, config *rest.Config) {

// ValidateArgs validates the arguments passed to the program
// and creates the output directory if it doesn't exist
func ValidateArgs(clientSet *kubernetes.Clientset, config *rest.Config) {
func ValidateArgs() {
if viper.Get("focus") == "" {
viper.Set("focus", "\\[Conformance\\]")
}
Expand Down
2 changes: 1 addition & 1 deletion pkg/common/args_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,7 @@ func TestValidateArgs(t *testing.T) {
viper.Set("extra-args", tc.extraArgs)

// Call the function under test
ValidateArgs(nil, nil)
ValidateArgs()
if viper.GetString("skip") != tc.expectedSkip {
t.Errorf("expected skip to be [%s], got [%s]", tc.expectedSkip, viper.GetString("skip"))
}
Expand Down

0 comments on commit 14110a7

Please sign in to comment.