diff --git a/pkg/test/ginkgo/cmd_runsuite.go b/pkg/test/ginkgo/cmd_runsuite.go index 6b8bc2e3b7df..4652c622072e 100644 --- a/pkg/test/ginkgo/cmd_runsuite.go +++ b/pkg/test/ginkgo/cmd_runsuite.go @@ -454,6 +454,11 @@ func (o *GinkgoRunSuiteOptions) Run(suite *TestSuite, clusterConfig *clusterdisc return strings.Contains(t.name, "[sig-cli] oc adm must-gather") }) + // separate ProjectAPI tests + projectAPITests, openshiftTests := splitTests(openshiftTests, func(t *testCase) bool { + return strings.Contains(t.name, "ProjectAPI") + }) + logrus.Infof("Found %d openshift tests", len(openshiftTests)) logrus.Infof("Found %d kubernetes tests", len(kubeTests)) logrus.Infof("Found %d storage tests", len(storageTests)) @@ -461,6 +466,7 @@ func (o *GinkgoRunSuiteOptions) Run(suite *TestSuite, clusterConfig *clusterdisc logrus.Infof("Found %d network tests", len(networkTests)) logrus.Infof("Found %d builds tests", len(buildsTests)) logrus.Infof("Found %d must-gather tests", len(mustGatherTests)) + logrus.Infof("Found %d ProjectAPI tests", len(projectAPITests)) // If user specifies a count, duplicate the kube and openshift tests that many times. expectedTestCount := len(early) + len(late) @@ -472,6 +478,7 @@ func (o *GinkgoRunSuiteOptions) Run(suite *TestSuite, clusterConfig *clusterdisc originalNetwork := networkTests originalBuilds := buildsTests originalMustGather := mustGatherTests + originalProjectAPI := projectAPITests for i := 1; i < count; i++ { kubeTests = append(kubeTests, copyTests(originalKube)...) @@ -481,9 +488,10 @@ func (o *GinkgoRunSuiteOptions) Run(suite *TestSuite, clusterConfig *clusterdisc networkTests = append(networkTests, copyTests(originalNetwork)...) buildsTests = append(buildsTests, copyTests(originalBuilds)...) mustGatherTests = append(mustGatherTests, copyTests(originalMustGather)...) + projectAPITests = append(projectAPITests, copyTests(originalProjectAPI)...) } } - expectedTestCount += len(openshiftTests) + len(kubeTests) + len(storageTests) + len(networkK8sTests) + len(networkTests) + len(buildsTests) + len(mustGatherTests) + expectedTestCount += len(openshiftTests) + len(kubeTests) + len(storageTests) + len(networkK8sTests) + len(networkTests) + len(buildsTests) + len(mustGatherTests) + len(projectAPITests) abortFn := neverAbort testCtx := ctx @@ -534,6 +542,10 @@ func (o *GinkgoRunSuiteOptions) Run(suite *TestSuite, clusterConfig *clusterdisc mustGatherTestsCopy := copyTests(mustGatherTests) q.Execute(testCtx, mustGatherTestsCopy, parallelism, testOutputConfig, abortFn) tests = append(tests, mustGatherTestsCopy...) + + projectAPITestsCopy := copyTests(projectAPITests) + q.Execute(testCtx, projectAPITestsCopy, parallelism, testOutputConfig, abortFn) + tests = append(tests, projectAPITestsCopy...) } // TODO: will move to the monitor