Skip to content

Commit

Permalink
Add testcontainer logs
Browse files Browse the repository at this point in the history
  • Loading branch information
Grzegorz Kołakowski committed Nov 22, 2023
1 parent 472439b commit f7dc31a
Show file tree
Hide file tree
Showing 2 changed files with 41 additions and 2 deletions.
26 changes: 24 additions & 2 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@
</scm>

<properties>
<maven.compiler.source>8</maven.compiler.source>
<maven.compiler.target>8</maven.compiler.target>
<maven.compiler.source>11</maven.compiler.source>
<maven.compiler.target>11</maven.compiler.target>
<scala.binary.version>2.12</scala.binary.version>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>

Expand All @@ -58,7 +58,9 @@

<assertj.version>3.23.1</assertj.version>
<junit.version>5.9.1</junit.version>
<logback.version>1.3.5</logback.version>
<mockito.version>2.21.0</mockito.version>
<slf4j-api.version>2.0.4</slf4j-api.version>
<testcontainers.version>1.18.2</testcontainers.version>
</properties>

Expand Down Expand Up @@ -242,6 +244,26 @@
<scope>test</scope>
</dependency>

<!-- Logging dependencies for testcontainers -->
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-core</artifactId>
<version>${logback.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>${slf4j-api.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>ch.qos.logback</groupId>
<artifactId>logback-classic</artifactId>
<version>${logback.version}</version>
<scope>test</scope>
</dependency>

<!-- Flink test dependencies -->
<dependency>
<groupId>org.apache.flink</groupId>
Expand Down
17 changes: 17 additions & 0 deletions src/test/resources/logback-test.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
<configuration>
<appender name="STDOUT" class="ch.qos.logback.core.ConsoleAppender">
<encoder>
<pattern>%d{HH:mm:ss.SSS} [%thread] %-5level %logger - %msg%n</pattern>
</encoder>
</appender>

<root level="ERROR">
<appender-ref ref="STDOUT"/>
</root>

<logger name="org.testcontainers" level="DEBUG"/>
<!-- The following logger can be used for containers logs since 1.18.0 -->
<logger name="tc" level="INFO"/>
<logger name="com.github.dockerjava" level="INFO"/>
<logger name="com.github.dockerjava.zerodep.shaded.org.apache.hc.client5.http.wire" level="OFF"/>
</configuration>

0 comments on commit f7dc31a

Please sign in to comment.