Skip to content

Commit a3cb741

Browse files
committed
Fix flaky gradle integration test
1 parent c7ea034 commit a3cb741

File tree

1 file changed

+3
-0
lines changed

1 file changed

+3
-0
lines changed

buildSrc/src/test/java/org/elasticsearch/gradle/testclusters/TestClustersPluginIT.java

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -55,6 +55,9 @@ public void testUseClusterByTwo() {
5555
}
5656

5757
public void testUseClusterByUpToDateTask() {
58+
// Run it once, ignoring the result and again to make sure it's considered up to date.
59+
// Gradle randomly considers tasks without inputs and outputs as as up-to-date or success on the first run
60+
getTestClustersRunner("upToDate1", "upToDate2").build();
5861
BuildResult result = getTestClustersRunner("upToDate1", "upToDate2").build();
5962
assertTaskUpToDate(result, ":upToDate1", ":upToDate2");
6063
assertNotStarted(result);

0 commit comments

Comments
 (0)