@@ -21,7 +21,8 @@ func InitializeJobs(ctx context.Context, log logr.Logger, k6 *v1alpha1.TestRun,
2121 // initializer is a quick job so check in frequently
2222 res = ctrl.Result {RequeueAfter : time .Second * 5 }
2323
24- cli := types .ParseCLI (k6 .GetSpec ().Arguments )
24+ // validation has already happened, so error here can be ignored
25+ cli , _ := types .ParseCLI (k6 .GetSpec ().Arguments )
2526
2627 var initializer * batchv1.Job
2728 if initializer , err = jobs .NewInitializerJob (k6 , cli .ArchiveArgs ); err != nil {
@@ -50,7 +51,8 @@ func RunValidations(ctx context.Context, log logr.Logger, k6 *v1alpha1.TestRun,
5051 // initializer is a quick job so check in frequently
5152 res = ctrl.Result {RequeueAfter : time .Second * 5 }
5253
53- cli := types .ParseCLI (k6 .GetSpec ().Arguments )
54+ // validation has already happened, so error here can be ignored
55+ cli , _ := types .ParseCLI (k6 .GetSpec ().Arguments )
5456
5557 inspectOutput , inspectReady , err := inspectTestRun (ctx , log , k6 , r .Client )
5658 if err != nil {
@@ -63,7 +65,7 @@ func RunValidations(ctx context.Context, log logr.Logger, k6 *v1alpha1.TestRun,
6365 WithAbort ()
6466 cloud .SendTestRunEvents (r .k6CloudClient , k6 .TestRunID (), log , events )
6567 } else {
66- // if there is any error, we have to reflect it on the K6 manifest
68+ // if there is any error, we have to reflect it on the TestRun manifest
6769 k6 .GetStatus ().Stage = "error"
6870 if _ , err := r .UpdateStatus (ctx , k6 , log ); err != nil {
6971 return ctrl.Result {}, ready , err
0 commit comments