I have worked spring boot + testcontainers test based on JUnit 4.
Example:
@RunWith(SpringRunner.class)
@SpringBootTest
public Test {
...
public void someTest() {
...
}
...
}
test properties:
spring:
datasource:
driver-class-name: org.testcontainers.jdbc.ContainerDatabaseDriver
url: jdbc:tc:mysql:5.6://hostname/db?TC_MY_CNF=mysql
username: user
password: pass
this test works properly, testcontainers uses JDBC Url string to initiate test container with MySQL 5.6.
Now I wanted to remove junit 4 from the project in favor to use JUnit 5.
Does testcontainers + Spring boot have ability to initiate containers in the similar way (by using JDBC URL) but using JUnit 5?
If yes - how to do it, or which workaround may be used here?
JavaScript questions and answers, JavaScript questions pdf, JavaScript question bank, JavaScript questions and answers pdf, mcq on JavaScript pdf, JavaScript questions and solutions, JavaScript mcq Test , Interview JavaScript questions, JavaScript Questions for Interview, JavaScript MCQ (Multiple Choice Questions)