From 360934a59b87cd6bdb59b1d15231e9246bec8517 Mon Sep 17 00:00:00 2001 From: "dependabot[bot]" <49699333+dependabot[bot]@users.noreply.github.com> Date: Mon, 11 Sep 2023 14:32:37 -0700 Subject: [PATCH] Bump org.junit.jupiter:junit-jupiter from 5.9.1 to 5.10.0 (#659) * Bump org.junit.jupiter:junit-jupiter from 5.9.1 to 5.10.0 Bumps [org.junit.jupiter:junit-jupiter](https://github.com/junit-team/junit5) from 5.9.1 to 5.10.0. - [Release notes](https://github.com/junit-team/junit5/releases) - [Commits](https://github.com/junit-team/junit5/compare/r5.9.1...r5.10.0) --- updated-dependencies: - dependency-name: org.junit.jupiter:junit-jupiter dependency-type: direct:development update-type: version-update:semver-minor ... Signed-off-by: dependabot[bot] * Fix dependabot version conflict * Improve test reliability --------- Signed-off-by: dependabot[bot] Co-authored-by: dependabot[bot] <49699333+dependabot[bot]@users.noreply.github.com> Co-authored-by: Bryan Burkholder --- kaldb/pom.xml | 7 ++++--- .../chunkManager/IndexingChunkManagerTest.java | 17 +++++++++++++---- 2 files changed, 17 insertions(+), 7 deletions(-) diff --git a/kaldb/pom.xml b/kaldb/pom.xml index fe9e6469fc..6b34b9e383 100644 --- a/kaldb/pom.xml +++ b/kaldb/pom.xml @@ -31,6 +31,7 @@ 2.20.0 2.20.116 2.16 + 5.10.0 @@ -377,19 +378,19 @@ org.junit.jupiter junit-jupiter - 5.9.1 + ${junit.jupiter.version} test org.junit.jupiter junit-jupiter-api - 5.9.1 + ${junit.jupiter.version} test org.junit.platform junit-platform-launcher - 1.9.3 + 1.10.0 org.awaitility diff --git a/kaldb/src/test/java/com/slack/kaldb/chunkManager/IndexingChunkManagerTest.java b/kaldb/src/test/java/com/slack/kaldb/chunkManager/IndexingChunkManagerTest.java index 91679789d3..09bac9776f 100644 --- a/kaldb/src/test/java/com/slack/kaldb/chunkManager/IndexingChunkManagerTest.java +++ b/kaldb/src/test/java/com/slack/kaldb/chunkManager/IndexingChunkManagerTest.java @@ -1422,11 +1422,20 @@ private void insertMessages( actualMessagesGauge++; actualBytesGauge += msgSize; if (actualMessagesGauge < msgsPerChunk) { - assertThat(getValue(LIVE_MESSAGES_INDEXED, metricsRegistry)).isEqualTo(actualMessagesGauge); - assertThat(getValue(LIVE_BYTES_INDEXED, metricsRegistry)).isEqualTo(actualBytesGauge); + final int finalActualMessagesGauge = actualMessagesGauge; + await() + .until( + () -> getValue(LIVE_MESSAGES_INDEXED, metricsRegistry), + (value) -> value == finalActualMessagesGauge); + final int finalActualBytesGauge = actualBytesGauge; + await() + .until( + () -> getValue(LIVE_BYTES_INDEXED, metricsRegistry), + (value) -> value == finalActualBytesGauge); } else { // Gauge is reset on roll over - assertThat(getValue(LIVE_MESSAGES_INDEXED, metricsRegistry)).isEqualTo(0); - assertThat(getValue(LIVE_BYTES_INDEXED, metricsRegistry)).isEqualTo(0); + await() + .until(() -> getValue(LIVE_MESSAGES_INDEXED, metricsRegistry), (value) -> value == 0); + await().until(() -> getValue(LIVE_BYTES_INDEXED, metricsRegistry), (value) -> value == 0); } } }