Skip to content

Commit

Permalink
Skip agent and beat recipes tests on OCP3 (#4388)
Browse files Browse the repository at this point in the history
We already skip agent and beat recipes tests on OCP.
This commit updates the test to ignore these tests, to extend it to OCP3.
  • Loading branch information
thbkrkr authored Mar 29, 2021
1 parent 82530c4 commit 2c3d85b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion test/e2e/agent/recipes_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ package agent
import (
"path"
"testing"
"strings"

agentv1alpha1 "github.com/elastic/cloud-on-k8s/pkg/apis/agent/v1alpha1"
"github.com/elastic/cloud-on-k8s/pkg/controller/common/version"
Expand Down Expand Up @@ -91,7 +92,7 @@ func runBeatRecipe(

// OpenShift requires different securityContext than provided in the recipe.
// Skipping it altogether to reduce maintenance burden.
if test.Ctx().Provider == "ocp" {
if strings.HasPrefix(test.Ctx().Provider, "ocp") {
t.SkipNow()
}

Expand Down
2 changes: 1 addition & 1 deletion test/e2e/beat/recipes_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -242,7 +242,7 @@ func runBeatRecipe(

// OpenShift requires different securityContext than provided in the recipe.
// Skipping it altogether to reduce maintenance burden.
if test.Ctx().Provider == "ocp" {
if strings.HasPrefix(test.Ctx().Provider, "ocp") {
t.SkipNow()
}

Expand Down

0 comments on commit 2c3d85b

Please sign in to comment.