-
Notifications
You must be signed in to change notification settings - Fork 26
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
SRVKP-6722 new tests for versioned ecosystem tasks #543
base: master
Are you sure you want to change the base?
Conversation
6d8ab97
to
9396126
Compare
@@ -63,4 +63,15 @@ Importance: Critical | |||
Pos/Neg: Negative |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Why does this have 05
in ID? 🤔
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nope... we removed IDs 1 to 5 and we shouldn't reuse the IDs. This one should be 09, following ones 10 and 11
specs/operator/addon.spec
Outdated
|
||
## Verify versioned ecosystem tasks: PIPELINES-15-TC09 | ||
Tags: e2e, integration, admin, addon, sanity |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this doesn't need to run as admin, remove sanity
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
steps/cli/oc.go
Outdated
@@ -165,6 +166,16 @@ var _ = gauge.Step("Update addon config with resolverStepActions as <resolverSte | |||
} | |||
}) | |||
|
|||
var _ = gauge.Step("Verify test versioned ecosystem task", func() { | |||
taskList := cmd.MustSucceed("oc", "get", "task", "-n", "openshift-pipelines").Stdout() | |||
requriedTasks := []string{"git-cli", "git-clone", "s2i-go", "s2i-python"} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
- typo
- extend this list to all tasks
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
steps/cli/oc.go
Outdated
taskList := cmd.MustSucceed("oc", "get", "task", "-n", "openshift-pipelines").Stdout() | ||
requriedTasks := []string{"git-cli", "git-clone", "s2i-go", "s2i-python"} | ||
for _, task := range requriedTasks { | ||
if !strings.Contains(taskList, task) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are supposed to check versioned tasks but you don't check those.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
steps/cli/oc.go
Outdated
requriedTasks := []string{"git-cli", "git-clone", "s2i-go", "s2i-python"} | ||
for _, task := range requriedTasks { | ||
if !strings.Contains(taskList, task) { | ||
testsuit.T.Errorf("Failed to test versioned task, No task found!!") |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Provide context in error message ... which task was not found?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
9396126
to
9890596
Compare
@@ -63,4 +63,15 @@ Importance: Critical | |||
Pos/Neg: Negative |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
nope... we removed IDs 1 to 5 and we shouldn't reuse the IDs. This one should be 09, following ones 10 and 11
specs/operator/addon.spec
Outdated
|
||
Steps: | ||
* Verify versioned stepaction tasks |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
* Verify versioned stepaction tasks | |
* Verify versioned ecosystem step actions |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
steps/cli/oc.go
Outdated
var _ = gauge.Step("Verify versioned ecosystem tasks", func() { | ||
taskList := cmd.MustSucceed("oc", "get", "task", "-n", "openshift-pipelines").Stdout() | ||
requiredTasks := []string{"buildah", "git-cli", "git-clone", "kn", "kn-apply", "maven", "openshift-client", "s2i-dotnet", "s2i-go", "s2i-java", "s2i-nodejs", "s2i-perl", "s2i-php", "s2i-python", "s2i-ruby", "skopeo-copy", "tkn"} | ||
requiredVersions := []string{"1-16-0", "1-17-0"} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You cannot hard-code versions here, that would increase maintenance burden. Just read the expected version from env variable OSP_VERSION
as defined env/default/default.properties
. You need to transform the string but that is not a big deal. It's enough to verify current version, you don't need to check all versions.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
steps/cli/oc.go
Outdated
for _, version := range requiredVersions { | ||
taskWithVersion := task + "-" + version | ||
if !strings.Contains(taskList, taskWithVersion) { | ||
testsuit.T.Errorf("Failed to test versioned task, No task found: %s", taskWithVersion) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
testsuit.T.Errorf("Failed to test versioned task, No task found: %s", taskWithVersion) | |
testsuit.T.Errorf("Task %s not found in namespace openshift-pipelines", taskWithVersion) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
steps/cli/oc.go
Outdated
} | ||
}) | ||
|
||
var _ = gauge.Step("Verify versioned stepaction tasks", func() { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
same as above
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Done
9890596
to
0242650
Compare
No description provided.