Testcontainers module for the MS SQL Server database.
Running MS SQL Server as a stand-in for in a test:
public class SomeTest {
@Rule
public MSSQLServerContainer mssqlserver = new MSSQLServerContainer();
@Test
public void someTestMethod() {
String url = mssqlserver.getJdbcUrl();
... create a connection and run test as normalNote: Due to licencing restrictions you are required to accept an EULA for this container image. To indicate that you accept the MS SQL Server image EULA, Please place a file at the root of the classpath named
container-license-acceptance.txt, e.g. atsrc/test/resources/container-license-acceptance.txt. This file should contain the line:microsoft/mssql-server-linux:latest
Replace VERSION with the latest version available on Maven Central.
<dependency>
<groupId>org.testcontainers</groupId>
<artifactId>mssqlserver</artifactId>
<version>VERSION</version>
</dependency>
compile group: 'org.testcontainers', name: 'mssqlserver', version: 'VERSION'
See LICENSE.
Copyright (c) 2017 - 2019 G DATA Software AG and other authors.
See AUTHORS for contributors.