Skip to content

Commit 68bff3a

Browse files
chore(ci): enable quality gates (#11710)
Enable Quality Gates to prevent new flaky tests from being merged into main or release branches. Example branches: https://github.com/DataDog/dd-trace-py/tree/erikayasuda/qg-simple-delayed-fix https://github.com/DataDog/dd-trace-py/tree/erikayasuda/qg-simple-quick-fix ## Checklist - [x] PR author has checked that all the criteria below are met - The PR description includes an overview of the change - The PR description articulates the motivation for the change - The change includes tests OR the PR description describes a testing strategy - The PR description notes risks associated with the change, if any - Newly-added code is easy to change - The change follows the [library release note guidelines](https://ddtrace.readthedocs.io/en/stable/releasenotes.html) - The change includes or references documentation updates if necessary - Backport labels are set (if [applicable](https://ddtrace.readthedocs.io/en/latest/contributing.html#backporting)) ## Reviewer Checklist - [x] Reviewer has checked that all the criteria below are met - Title is accurate - All changes are related to the pull request's stated goal - Avoids breaking [API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces) changes - Testing strategy adequately addresses listed risks - Newly-added code is easy to change - Release note makes sense to a user of the library - If necessary, author has acknowledged and discussed the performance implications of this PR as reported in the benchmarks PR comment - Backport labels are set in a manner that is consistent with the [release branch maintenance policy](https://ddtrace.readthedocs.io/en/latest/contributing.html#backporting) --------- Co-authored-by: erikayasuda <[email protected]>
1 parent d364f1b commit 68bff3a

File tree

1 file changed

+15
-0
lines changed

1 file changed

+15
-0
lines changed

.gitlab-ci.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@ stages:
22
- package
33
- tests-gen
44
- tests-trigger
5+
- quality-gate
56
- shared-pipeline
67
- benchmarks
78
- macrobenchmarks
@@ -87,3 +88,17 @@ deploy_to_di_backend:manual:
8788
UPSTREAM_COMMIT_AUTHOR: $CI_COMMIT_AUTHOR
8889
UPSTREAM_TAG: $CI_COMMIT_TAG
8990
UPSTREAM_PACKAGE_JOB: build
91+
92+
check_new_flaky_tests:
93+
stage: quality-gate
94+
extends: .testrunner
95+
script:
96+
- curl -L --fail "https://github.com/DataDog/datadog-ci/releases/latest/download/datadog-ci_linux-x64" --output "/usr/local/bin/datadog-ci" && chmod +x /usr/local/bin/datadog-ci
97+
- export DD_SITE=datadoghq.com
98+
- export DD_API_KEY=$(aws ssm get-parameter --region us-east-1 --name ci.${CI_PROJECT_NAME}.dd-api-key-qualitygate --with-decryption --query "Parameter.Value" --out text)
99+
- export DD_APP_KEY=$(aws ssm get-parameter --region us-east-1 --name ci.${CI_PROJECT_NAME}.dd-app-key-qualitygate --with-decryption --query "Parameter.Value" --out text)
100+
- datadog-ci gate evaluate
101+
except:
102+
- main
103+
- '[0-9].[0-9]*'
104+
- 'mq-working-branch**'

0 commit comments

Comments
 (0)