Skip to main content

Questions tagged [testcontainers]

TestContainers is a Java library that supports (JUnit) tests, providing lightweight, throwaway instances of common databases, Selenium web browsers, or anything else that can run in a Docker container.

testcontainers
-1 votes
0 answers
28 views

Integration Test Using Single Wiremock Server vs Separate TestContainers

I have a Containerized application which uses other containerized apps in environment to consume REST apis.After performing the business logic, it creates file and send it to a remote server using ...
Manish's user avatar
  • 1,429
0 votes
0 answers
15 views

Spring Boot: Integration tests using Testcontainers fail when using spring.data.mongodb.uri property, but work when using spring.data.mongodb.user etc

I have a set of working integration tests with Testcontainers and MongoDB container. As part of the test, an data import is done when running tests. For this, I've written a configuration class: @...
Christoph Dahlen's user avatar
0 votes
2 answers
24 views

Harcoding PortNumber for mockserver using testcontainers

I am using testcontainers to create a mockserver in JUnit5. It seems the port number changes for every run randomly, I want it to have a fix port number, which I will decide. how this can be done ? ...
Suman Shekhar's user avatar
0 votes
0 answers
14 views

No metadata for "User" was found using TypeORM, ExpressJS, Supertest and Testcontainers

I am trying to write integration tests for an expressjs application which uses TypeORM and a PostgreSQL database. The main application works fine without any issues with a main datasource, migrations ...
greazleay's user avatar
0 votes
0 answers
35 views

Testcontainers is spinning up server but not creating the schema

I am trying to create a project for my integration tests, that spin up a test container using docker. I'm also trying to then create my SQL Server. It creates the SQL Server fine, but its not creating ...
Leviathan's user avatar
  • 104
0 votes
0 answers
29 views

Spring boot Integration test data clean up issue

I have some integration tests in my spring boot tests. Around 20 of them. Before each integration test I am using @Sql annotation to inject some data and after the test I run a clean up script to ...
Sadatul islam Sadi's user avatar
-1 votes
0 answers
31 views

How to run `podman/newman` in `testcontainers`?

I'm trying to perform some integration tests with newman running in testcontainers. Given that the tests are supposed to be executed against AWS infrastructure, the URLs aren't known before the ...
Nicolas's user avatar
-2 votes
0 answers
16 views

Clarification needed regarding singleton testcontainers in Spring Boot tests

I'm trying to understand why the following happens as described in A common misconfiguration of Singleton Containers: ..."but the subsequent tests still try to connect to those stopped ...
Keith Bennett's user avatar
0 votes
1 answer
65 views

Unable to Connect to Azurite Container From Another Container in Docker Using TestContainers .NET Provided Connection String

I'm playing around with some integration tests using TestContainers for .NET, Azurite and an Azure Function App. I have an Azurite TestContainer declared: _azuriteContainer = new AzuriteBuilder() ....
James Law's user avatar
  • 6,485
0 votes
0 answers
28 views

Buildup of testcontainers (and memory consumption) when using Singleton Containers

If we follow the recommendations outlined in A common misconfiguration of Singleton Containers, where we use @BeforeAll to start containers (instead of @Testcontainers, @Container, and @...
Keith Bennett's user avatar
2 votes
2 answers
42 views

Adding Data to a testcontainer using a function from a repository

I've set up a testcontainer for use during integration testing. Whilst it works and the test data is upserted to the test container, I cannot accurately check that my repository function, using JOOq, ...
tcampbell649's user avatar
0 votes
0 answers
34 views

Testcontainer Integration Test works with mvn verify but not within Eclipse

On linux fedora I have a JUnit 5 integration test that starts and uses a org.testcontainers.containers.PostgreSQLContainer The test run successfully when using mvn clean verify However, running them ...
Lukas Weber's user avatar
0 votes
0 answers
46 views

How to Use WebApplicationFactory with Testcontainers for SpecFlow Tests?

I'm working on a .NET project where I want to integrate WebApplicationFactory with Testcontainers to use PostgreSQL for my SpecFlow tests. I'm facing some challenges ensuring that the PostgreSQL ...
Hasan Kanaan's user avatar
0 votes
1 answer
56 views

Spring boot using kafka container for integration tests

HI so i had a spring boot application very basic which was posting to kafka topic I had an integration test witha container set up as follows: protected static final KafkaContainer KAFKA_CONTAINER = ...
user1555190's user avatar
  • 3,133
0 votes
0 answers
22 views

Grails 6.2.x database integration tests without testcontainer

On my previous projects I used grails 4.x and created integration tests with database access using spock. Now I am starting a new project with Grails 6.2.0 and it seems to require testcontainers for ...
Matt's user avatar
  • 384

15 30 50 per page
1
2 3 4 5
73