testcontainers-java-examples icon indicating copy to clipboard operation
testcontainers-java-examples copied to clipboard

Build Fails with dependency error

Open gclayburg opened this issue 7 years ago • 0 comments

mvn clean install fails with this error:

testNotFindingAValueThatWasNotInserted(RedisBackedCacheTest)  Time elapsed: 0.005 sec  <<< ERROR!
java.lang.NoClassDefFoundError: org/apache/commons/codec/binary/Base64
	at com.github.dockerjava.core.AuthConfigFile.decodeAuth(AuthConfigFile.java:178)
	at com.github.dockerjava.core.AuthConfigFile.loadConfig(AuthConfigFile.java:140)
	at com.github.dockerjava.core.DefaultDockerClientConfig.effectiveAuthConfig(DefaultDockerClientConfig.java:266)
	at com.github.dockerjava.core.DockerClientImpl.pullImageCmd(DockerClientImpl.java:215)
	at org.testcontainers.dockerclient.AuditLoggingDockerClient.pullImageCmd(AuditLoggingDockerClient.java:22)
	at org.testcontainers.DockerClientFactory.checkAndPullImage(DockerClientFactory.java:183)
	at org.testcontainers.utility.ResourceReaper.start(ResourceReaper.java:65)
	at org.testcontainers.DockerClientFactory.client(DockerClientFactory.java:116)
	at org.testcontainers.containers.GenericContainer.<init>(GenericContainer.java:126)
	at RedisBackedCacheTest.<init>(RedisBackedCacheTest.java:18)

I was able to work around it by adding this dependency in the root pom.xml:

        <dependency>
            <groupId>commons-codec</groupId>
            <artifactId>commons-codec</artifactId>
            <version>1.10</version>
        </dependency>

Would a PR help? Or maybe there is a better place to add this?

gclayburg avatar Mar 12 '18 17:03 gclayburg