Commit 7cdcfe5b authored by Andrejs Cunskis's avatar Andrejs Cunskis Committed by Rémy Coutable

Use pipeline-common for allure report and knapsack report jobs

parent da95afc6
include:
- project: gitlab-org/quality/pipeline-common
ref: 0.3.6
file:
- /ci/allure-report.yml
- /ci/knapsack-report.yml
.review-qa-base: .review-qa-base:
extends: extends:
- .use-docker-in-docker - .use-docker-in-docker
...@@ -43,27 +50,13 @@ ...@@ -43,27 +50,13 @@
when: always when: always
.allure-report-base: .allure-report-base:
image: extends: .generate-allure-report-base
name: ${GITLAB_DEPENDENCY_PROXY}andrcuns/allure-report-publisher:0.4.2
entrypoint: [""]
stage: post-qa stage: post-qa
variables: variables:
GIT_STRATEGY: none
STORAGE_CREDENTIALS: $QA_ALLURE_REPORT_GCS_CREDENTIALS
GITLAB_AUTH_TOKEN: $GITLAB_QA_MR_ALLURE_REPORT_TOKEN GITLAB_AUTH_TOKEN: $GITLAB_QA_MR_ALLURE_REPORT_TOKEN
ALLURE_PROJECT_PATH: $CI_PROJECT_PATH ALLURE_PROJECT_PATH: $CI_PROJECT_PATH
ALLURE_MERGE_REQUEST_IID: $CI_MERGE_REQUEST_IID ALLURE_MERGE_REQUEST_IID: $CI_MERGE_REQUEST_IID
allow_failure: true ALLURE_RESULTS_GLOB: qa/tmp/allure-results/*
script:
- |
allure-report-publisher upload gcs \
--results-glob="qa/tmp/allure-results/*" \
--bucket="gitlab-qa-allure-reports" \
--prefix="$ALLURE_REPORT_PATH_PREFIX/$CI_COMMIT_REF_SLUG" \
--update-pr="comment" \
--copy-latest \
--ignore-missing-results \
--color
review-qa-smoke: review-qa-smoke:
extends: extends:
...@@ -121,23 +114,19 @@ review-performance: ...@@ -121,23 +114,19 @@ review-performance:
performance: performance.json performance: performance.json
expire_in: 31d expire_in: 31d
allure-report-qa-smoke: # Generate single report for both smoke and reliable test jobs
extends: # Both job types are essentially the same:
- .allure-report-base # * always executed
- .review:rules:review-qa-smoke-report # * always blocking
needs: ["review-qa-smoke"] allure-report-qa-blocking:
variables:
ALLURE_REPORT_PATH_PREFIX: gitlab-review-smoke
ALLURE_JOB_NAME: review-qa-smoke
allure-report-qa-reliable:
extends: extends:
- .allure-report-base - .allure-report-base
- .review:rules:review-qa-reliable-report - .review:rules:review-qa-blocking-report
needs: ["review-qa-reliable"] needs:
- review-qa-smoke
- review-qa-reliable
variables: variables:
ALLURE_REPORT_PATH_PREFIX: gitlab-review-reliable ALLURE_JOB_NAME: review-qa-blocking
ALLURE_JOB_NAME: review-qa-reliable
allure-report-qa-all: allure-report-qa-all:
extends: extends:
...@@ -145,18 +134,11 @@ allure-report-qa-all: ...@@ -145,18 +134,11 @@ allure-report-qa-all:
- .review:rules:review-qa-all-report - .review:rules:review-qa-all-report
needs: ["review-qa-all"] needs: ["review-qa-all"]
variables: variables:
ALLURE_REPORT_PATH_PREFIX: gitlab-review-all
ALLURE_JOB_NAME: review-qa-all ALLURE_JOB_NAME: review-qa-all
knapsack-report: knapsack-report:
extends: extends:
- .review:rules:knapsack-report - .generate-knapsack-report-base
image:
name: ${QA_IMAGE}
entrypoint: [""]
stage: post-qa stage: post-qa
allow_failure: true variables:
before_script: QA_KNAPSACK_REPORT_FILE_PATTERN: $CI_PROJECT_DIR/tmp/knapsack/*/*.json
- cd qa
script:
- bundle exec rake 'knapsack:upload[tmp/knapsack/*/*.json]'
...@@ -1583,17 +1583,12 @@ ...@@ -1583,17 +1583,12 @@
# #
# See https://gitlab.com/gitlab-org/gitlab/-/merge_requests/76756 # See https://gitlab.com/gitlab-org/gitlab/-/merge_requests/76756
# Since `review-qa-smoke` isn't allowed to fail, we need to use `when: always` for `review-qa-smoke-report`.
.review:rules:review-qa-smoke-report:
rules:
- when: always
.review:rules:review-qa-reliable: .review:rules:review-qa-reliable:
rules: rules:
- when: on_success - when: on_success
# Since `review-qa-reliable` isn't allowed to fail, we need to use `when: always`for `review-qa-reliable-report`. # Since `review-qa-reliable` isn't allowed to fail, we need to use `when: always`for `review-qa-reliable-report`.
.review:rules:review-qa-reliable-report: .review:rules:review-qa-blocking-report:
rules: rules:
- when: always - when: always
...@@ -1613,11 +1608,6 @@ ...@@ -1613,11 +1608,6 @@
- when: on_success - when: on_success
- when: on_failure - when: on_failure
.review:rules:knapsack-report:
rules:
- if: '$KNAPSACK_GENERATE_REPORT == "true"'
when: always
.review:rules:review-cleanup: .review:rules:review-cleanup:
rules: rules:
- <<: *if-not-ee - <<: *if-not-ee
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment