Skip to content

Switch tests to use Testcontainers instead of postgres database#494

Merged
alex-odysseus merged 1 commit intodevelopfrom
testcontainers
Nov 5, 2021
Merged

Switch tests to use Testcontainers instead of postgres database#494
alex-odysseus merged 1 commit intodevelopfrom
testcontainers

Conversation

@dmitrys-odysseus
Copy link
Copy Markdown
Contributor

Also, java-docker is upgraded 3.2.7 -> 3.2.11 as the latter is required for testcontainers.

import org.testcontainers.shaded.com.google.common.collect.ImmutableMap;

public class TestContainersInitializer implements ApplicationContextInitializer<ConfigurableApplicationContext> {
static PostgreSQLContainer<?> postgres = new PostgreSQLContainer<>();
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

'postgre' or 'postgreSql', please

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nevermind

Comment thread pom.xml
<dependency>
<groupId>org.testcontainers</groupId>
<artifactId>testcontainers</artifactId>
<version>1.16.0</version>
Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Any arguments not to use the latest version 1.16.2?

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To be addressed in the future

@alex-odysseus alex-odysseus merged commit a8bdeb1 into develop Nov 5, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants