I am trying to write a simple test using Java 11 and TestContainers. However, the compiler is giving following errors.
The module-info.java looks like the following.
module com.oif.reader {
requires org.junit.jupiter.api;
requires org.junit.jupiter.engine;
requires java.instrument;
requires java.sql;
requires testcontainers;
}
The test is quite simple. It's very basic at the moment.
package com.oif.reader.integration;
import org.junit.jupiter.api.Test;
import org.testcontainers.containers.MySQLContainer;
import org.testcontainers.junit.jupiter.Container;
import org.testcontainers.junit.jupiter.Testcontainers;
@Testcontainers
public class GenericTest {
@Container
private static final MySQLContainer MY_SQL_CONTAINER = new MySQLContainer();
@Test
public void name() {
String url = MY_SQL_CONTAINER.getJdbcUrl();
System.out.println(url);
}
}
Java Compiler gives the following errors.
error: module junit.jupiter reads package org.newsclub.net.unix from both junixsocket.common and junixsocket.native.common
There are about 50 of them similar to this. Any idea on how to fix these issues?