Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions .github/workflows/test-on-docker.yml
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,19 @@ jobs:
mvn -Dtest=$TESTS clean compile test
fi
env:
JVM_OPTS: "-XX:+PrintFlagsFinal -XX:+HeapDumpOnOutOfMemoryError -XX:+ExitOnOutOfMemoryError -XX:HeapDumpPath=${{ runner.temp }}/heapdump-${{ matrix.redis_version }}.hprof"
TESTS: ${{ github.event.inputs.specific_test || '' }}
- name: Upload Heap Dumps
if: failure()
uses: actions/upload-artifact@v4
with:
name: heap-dumps-${{ matrix.redis_version }}
path: ${{ runner.temp }}/heapdump-${{ matrix.redis_version }}.hprof
- name: Upload Surefire Dump File
uses: actions/upload-artifact@v3
with:
name: surefire-dumpstream
path: target/surefire-reports/*.dumpstream
- name: Publish Test Results
uses: EnricoMi/publish-unit-test-result-action@v2
if: always()
Expand Down
1 change: 1 addition & 0 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -234,6 +234,7 @@
<artifactId>maven-surefire-plugin</artifactId>
<version>${maven.surefire.version}</version>
<configuration>
<argLine>${JVM_OPTS}</argLine>
<systemPropertyVariables>
<redis-hosts>${redis-hosts}</redis-hosts>
</systemPropertyVariables>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -83,6 +83,7 @@ public void evict() throws Exception {

await().pollInterval(ONE_HUNDRED_MILLISECONDS).atMost(FIVE_HUNDRED_MILLISECONDS)
.until(numberOfEvictions::get, Matchers.greaterThanOrEqualTo(1));
pool.close();
}

public void withLowerRefreshBounds_testJedisAuthXManagerTriggersEvict() throws Exception {
Expand All @@ -108,6 +109,7 @@ public void evict() throws Exception {

await().pollInterval(ONE_HUNDRED_MILLISECONDS).atMost(FIVE_HUNDRED_MILLISECONDS)
.until(numberOfEvictions::get, Matchers.greaterThanOrEqualTo(1));
pool.close();
}

public static class TokenManagerConfigWrapper extends TokenManagerConfig {
Expand Down Expand Up @@ -229,6 +231,7 @@ public void testAuthXManagerReceivesNewToken()

manager.start();
assertEquals(tokenHolder[0].getValue(), "tokenVal");
manager.stop();
}

@Test
Expand Down Expand Up @@ -300,6 +303,7 @@ public void testTokenManagerWithFailingTokenRequest()
verify(identityProvider, times(numberOfRetries)).requestToken();
verify(listener, never()).onError(any());
assertEquals("tokenValX", argument.getValue().getValue());
tokenManager.stop();
}

@Test
Expand Down Expand Up @@ -338,5 +342,6 @@ public void testTokenManagerWithHangingTokenRequest()
await().atMost(2, TimeUnit.SECONDS).untilAsserted(() -> {
verify(manager, times(1)).authenticateConnections(any());
});
manager.stop();
}
}
Loading