Skip to content

[Backport 2.x] Retry tests only on CI server#5363

Closed
opensearch-trigger-bot[bot] wants to merge 1 commit into2.xfrom
backport/backport-5349-to-2.x
Closed

[Backport 2.x] Retry tests only on CI server#5363
opensearch-trigger-bot[bot] wants to merge 1 commit into2.xfrom
backport/backport-5349-to-2.x

Conversation

@opensearch-trigger-bot
Copy link
Copy Markdown
Contributor

Backport 741dc49 from #5349.

Retrying all tests by default is not great when developing tests. This
behavior could be missed by a developer and result in new flakiness
being introduced. This change will only enable retries when the "CI"
environment variable is present.

Signed-off-by: Andrew Ross <andrross@amazon.com>

Signed-off-by: Andrew Ross <andrross@amazon.com>
(cherry picked from commit 741dc49)
Signed-off-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
@opensearch-trigger-bot opensearch-trigger-bot bot requested review from a team and reta as code owners November 23, 2022 18:35
apply plugin: "org.gradle.test-retry"
tasks.withType(Test).configureEach {
retry {
if (isCiServer) {
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

BuildParams.isCI()

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Good call. Fixed here: #5368

I'll backport that one and close this PR.

@github-actions
Copy link
Copy Markdown
Contributor

Gradle Check (Jenkins) Run Completed with:

  • RESULT: UNSTABLE ❕
  • TEST FAILURES:
      1 org.opensearch.indices.stats.IndexStatsIT.testFilterCacheStats

@andrross andrross closed this Nov 23, 2022
@andrross andrross deleted the backport/backport-5349-to-2.x branch April 4, 2025 18:22
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants