Skip to content

Commit f03e5fc

Browse files
author
julien
committed
Streamlined teardown
1 parent 6a59e95 commit f03e5fc

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

subprojects/testcontainers-redis-junit/src/main/java/com/redis/testcontainers/junit/AbstractTestcontainersRedisTestBase.java

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -76,8 +76,10 @@ protected void flushAll() {
7676

7777
@AfterAll
7878
protected void teardown() {
79-
contexts.values().forEach(RedisTestContext::close);
80-
contexts.keySet().forEach(RedisServer::close);
79+
contexts.forEach((k, v) -> {
80+
v.close();
81+
k.close();
82+
});
8183
contexts.clear();
8284
}
8385

0 commit comments

Comments
 (0)