-
Notifications
You must be signed in to change notification settings - Fork 42
feat: support a comma-separated list of test suites #324
feat: support a comma-separated list of test suites #324
Conversation
.ci/Jenkinsfile
Outdated
@@ -237,20 +244,30 @@ pipeline { | |||
success { | |||
whenTrue(!isPR() && params.notifyOnGreenBuilds) { | |||
slackSend(channel: "#${env.SLACK_CHANNEL}", color: 'good', | |||
message: "[${params.runTestsSuite}] Build Passed: ${env.JOB_NAME} ${env.BUILD_NUMBER} (<${env.RUN_DISPLAY_URL}|Open>).", | |||
message: "[${params.runTestsSuites}] Build Passed: ${env.JOB_NAME} ${env.BUILD_NUMBER} (<${env.RUN_DISPLAY_URL}|Open>).", |
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.
Mmmm, this should have better format when multiple suites have been passed
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.
Another mmm... what if the value is empty (meaning all)?
💔 Tests FailedExpand to view the summary
Build stats
Test stats 🧪
Test errorsExpand to view the tests failures
Steps errorsExpand to view the steps failures
Log outputExpand to view the last 100 lines of log output
|
* chore: rename variable to represent godog tags * fix: double quote variable * chore: rename jenkins parameter * chore: use empty instead of all as value for the tags to be run * chore: simplify variable value * chore: rename variable * feat: support passing a comma-separated list of test suites to be run * chore: extract common code to a method * chore: rename variable * chore: trim test suite in the list * chore: add logs * fix: forgot "each" for the array * chore: extract slack send to a function * chore: format slack message * chore: format message for empty test suites * chore: rename variable to avoid conflicts with Jenkins params * chore: simplify loop Co-authored-by: Victor Martinez <[email protected]> * chore: simplify variables inside loop Co-authored-by: Victor Martinez <[email protected]> # Conflicts: # .ci/scripts/functional-test.sh
* chore: rename variable to represent godog tags * fix: double quote variable * chore: rename jenkins parameter * chore: use empty instead of all as value for the tags to be run * chore: simplify variable value * chore: rename variable * feat: support passing a comma-separated list of test suites to be run * chore: extract common code to a method * chore: rename variable * chore: trim test suite in the list * chore: add logs * fix: forgot "each" for the array * chore: extract slack send to a function * chore: format slack message * chore: format message for empty test suites * chore: rename variable to avoid conflicts with Jenkins params * chore: simplify loop Co-authored-by: Victor Martinez <[email protected]> * chore: simplify variables inside loop Co-authored-by: Victor Martinez <[email protected]> # Conflicts: # .ci/scripts/functional-test.sh
What does this PR do?
It refactors the jenkinsfile logic to support this. To achieve it, we:
Why is it important?
It will allow to execute more than one test suite from an upstream job (and also from here!)
Checklist
make notice
in the proper directory)How to test this locally
if we want to test that the refactor of the variables s OK, rom the root directory of the project:
$ SUITE=ingest-manager TAGS="fleet_mode && enroll" LOG_LEVEL=TRACE make -C e2e functional-test
Desired executed command:
godog --tags "fleet_mode && enroll"
About the comma-separated list of strings, it happens on Jenkins time, so not possible to test it locally.
Related issues
Screenshots
Running with
runTestsSuites="helm, metricbeat"
Follow-ups
Update elastic/beats#21100 with the updated parameter.