Skip to content

Commit

Permalink
Run integration tests in parallel
Browse files Browse the repository at this point in the history
Most of the tests in the integration suite can
be run in parallel to save time. This is due to the
fact that they all run in their own namespaces
anyways. If they conflict somehow we'll have to
debug that as well.

Fixes #1332

Signed-off-by: John Schnake <[email protected]>
  • Loading branch information
johnSchnake committed Jun 29, 2021
1 parent 576dcdb commit c738d7c
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions test/integration/sonobuoy_integration_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -110,6 +110,7 @@ func cleanup(t *testing.T, namespace string) {
}

func TestUseNamespaceFromManifest(t *testing.T) {
t.Parallel()
ctx, cancel := context.WithTimeout(context.Background(), defaultTestTimeout)
defer cancel()

Expand Down Expand Up @@ -141,6 +142,7 @@ func TestUseNamespaceFromManifest(t *testing.T) {

// TestSimpleRun runs a simple plugin to check that it runs successfully
func TestSimpleRun(t *testing.T) {
t.Parallel()
ctx, cancel := context.WithTimeout(context.Background(), defaultTestTimeout)
defer cancel()

Expand All @@ -152,6 +154,7 @@ func TestSimpleRun(t *testing.T) {
}

func TestRetrieveAndExtract(t *testing.T) {
t.Parallel()
ctx, cancel := context.WithTimeout(context.Background(), defaultTestTimeout)
defer cancel()

Expand Down Expand Up @@ -195,6 +198,7 @@ func TestRetrieveAndExtract(t *testing.T) {

// TestQuick runs a real "--mode quick" check against the cluster to ensure that it passes.
func TestQuick(t *testing.T) {
t.Parallel()
ctx, cancel := context.WithTimeout(context.Background(), defaultTestTimeout)
defer cancel()

Expand All @@ -212,6 +216,7 @@ func TestQuick(t *testing.T) {
}

func TestConfigmaps(t *testing.T) {
t.Parallel()
ctx, cancel := context.WithTimeout(context.Background(), defaultTestTimeout)
defer cancel()

Expand Down Expand Up @@ -324,6 +329,7 @@ func saveToArtifacts(t *testing.T, p string) (newPath string) {

// TestSonobuoyVersion checks that all fields in the output from `version` are non-empty
func TestSonobuoyVersion(t *testing.T) {
t.Parallel()
stdout := mustRunSonobuoyCommand(t, "version")

lines := strings.Split(stdout.String(), "\n")
Expand All @@ -338,6 +344,7 @@ func TestSonobuoyVersion(t *testing.T) {
}

func TestManualResultsJob(t *testing.T) {
t.Parallel()
ctx, cancel := context.WithTimeout(context.Background(), defaultTestTimeout)
defer cancel()

Expand All @@ -362,6 +369,7 @@ func TestManualResultsJob(t *testing.T) {
}

func TestManualResultsDaemonSet(t *testing.T) {
t.Parallel()
ctx, cancel := context.WithTimeout(context.Background(), defaultTestTimeout)
defer cancel()

Expand Down Expand Up @@ -391,6 +399,7 @@ func TestManualResultsDaemonSet(t *testing.T) {
}

func TestManualResultsWithNestedDetails(t *testing.T) {
t.Parallel()
ctx, cancel := context.WithTimeout(context.Background(), defaultTestTimeout)
defer cancel()

Expand Down

0 comments on commit c738d7c

Please sign in to comment.