| | |
| | | import org.testcontainers.oracle.OracleContainer; |
| | | import org.testng.annotations.Test; |
| | | |
| | | import java.time.Duration; |
| | | |
| | | //docker run --rm --name oracle-db -p 1521:1521 -e APP_USER=opendj -e ORACLE_DATABASE=database_name -e APP_USER_PASSWORD=password gvenzl/oracle-free:23.4-slim-faststart |
| | | |
| | | @Test |
| | | @Test(sequential = true) |
| | | public class OracleTestCase extends TestCase { |
| | | |
| | | @Override |
| | | protected JdbcDatabaseContainer<?> getContainer() { |
| | | return new OracleContainer("gvenzl/oracle-free:23.4-slim-faststart") |
| | | return new OracleContainer("gvenzl/oracle-free:23.6-faststart") |
| | | .withExposedPorts(1521) |
| | | .withUsername("opendj") |
| | | .withPassword("password") |
| | | .withDatabaseName("database_name") |
| | | .withStartupTimeout(Duration.ofMinutes(5)) |
| | | .withStartupAttempts(10); |
| | | } |
| | | |
| | |
| | | return "jdbc:oracle:thin:opendj/password@localhost: " + ((container==null)?"1521":container.getMappedPort(1521)) + "/database_name"; |
| | | } |
| | | |
| | | @Override |
| | | @Test(skipFailedInvocations = true) //ORA UPSERT error |
| | | public void test_issue_496_2() { |
| | | try { |
| | | super.test_issue_496_2(); |
| | | } catch (Exception e) { |
| | | assert true : "failed test"; |
| | | } |
| | | } |
| | | } |