Skip to content

Commit

Permalink
Re-enable testcontainers tests (#546)
Browse files Browse the repository at this point in the history
* testcontainers:1.17.6 - enable tests

* testcontainers:1.19.8 - enable tests

---------

Co-authored-by: David Nestorovic <[email protected]>
  • Loading branch information
Kehrlann and dnestoro authored Nov 5, 2024
1 parent 3e78314 commit 5fda11b
Show file tree
Hide file tree
Showing 8 changed files with 24 additions and 30 deletions.
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
nginx:1-alpine-slim
testcontainers/ryuk:0.10.2
Original file line number Diff line number Diff line change
Expand Up @@ -17,31 +17,16 @@

import static org.assertj.core.api.Assertions.assertThat;

// This test is pulling testcontainers/ryuk docker image version with many known vulnerabilities. It should be ignored until testcontainers change this image.
// ISSUE: https://github.com/oracle/graalvm-reachability-metadata/issues/250
class TestcontainersTest {
private static final boolean DEBUG = false;

// DO NOT REMOVE THIS! READ THE COMMENT ABOVE THE CLASS
// tests should be disabled until testconatiners/ryuk is fixed
private static final boolean IS_DISABLED = true;

@BeforeAll
static void beforeAll() {
// DO NOT REMOVE THIS! READ THE COMMENT ABOVE THE CLASS
if (IS_DISABLED) {
return;
}
System.setProperty("org.slf4j.simpleLogger.defaultLogLevel", DEBUG ? "debug" : "warn");
}

@Test
void test() throws Exception {
// DO NOT REMOVE THIS! READ THE COMMENT ABOVE THE CLASS
if (IS_DISABLED) {
return;
}

try (GenericContainer<?> nginx = new GenericContainer<>("nginx:1-alpine-slim")) {
nginx.withExposedPorts(80).start();
HttpClient httpClient = HttpClient.newBuilder().build();
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"bundles": [],
"resources": {
"includes": [
{
"pattern": "\\Qtestcontainers.properties\\E"
}
]
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ryuk.container.image=testcontainers/ryuk:0.10.2
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
nginx:1-alpine-slim
testcontainers/ryuk:0.10.2
Original file line number Diff line number Diff line change
Expand Up @@ -17,31 +17,16 @@

import static org.assertj.core.api.Assertions.assertThat;

// This test is pulling testcontainers/ryuk docker image version with many known vulnerabilities. It should be ignored until testcontainers change this image.
// ISSUE: https://github.com/oracle/graalvm-reachability-metadata/issues/250
class TestcontainersTest {
private static final boolean DEBUG = false;

// DO NOT REMOVE THIS! READ THE COMMENT ABOVE THE CLASS
// tests should be disabled until testconatiners/ryuk is fixed
private static final boolean IS_DISABLED = true;

@BeforeAll
static void beforeAll() {
// DO NOT REMOVE THIS! READ THE COMMENT ABOVE THE CLASS
if (IS_DISABLED) {
return;
}
System.setProperty("org.slf4j.simpleLogger.defaultLogLevel", DEBUG ? "debug" : "warn");
}

@Test
void test() throws Exception {
// DO NOT REMOVE THIS! READ THE COMMENT ABOVE THE CLASS
if (IS_DISABLED) {
return;
}

try (GenericContainer<?> nginx = new GenericContainer<>("nginx:1-alpine-slim")) {
nginx.withExposedPorts(80).start();
HttpClient httpClient = HttpClient.newBuilder().build();
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"bundles": [],
"resources": {
"includes": [
{
"pattern": "\\Qtestcontainers.properties\\E"
}
]
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
ryuk.container.image=testcontainers/ryuk:0.10.2

0 comments on commit 5fda11b

Please sign in to comment.