Skip to main content
Filter by
Sorted by
Tagged with
3 votes
1 answer
122 views

I am playing with Testcontainers and all the different approaches to use within a Spring Boot application. I am facing some strange issue. My tests should not be passing but it does and I don't ...
Saravana Kumar M's user avatar
3 votes
1 answer
49 views

I am trying to understand Testcontainers and all the different approaches to use within a Spring Boot application. I landed on a strange issue and could not figure out what is missing. I have the ...
Saravana Kumar M's user avatar
0 votes
1 answer
247 views

I'm using Spring boot 3.5.6 and below is my container configuration package com.transmonix.utils; import org.junit.jupiter.api.BeforeAll; import org.junit.jupiter.api.BeforeEach; import org....
Tarunjeet Singh Salh's user avatar
1 vote
1 answer
274 views

Can anyone using DBRider / Test Container in spring boot give advice ? I've been using DBRider/Testcontainer without any issue, but at some point , it doesn't work out. It seesm ...
Tony Lim's user avatar
0 votes
1 answer
197 views

I'm trying to create a local Docker registry using Testcontainers and push an image programatically to it. However, I'm getting a connection refused error when attempting to push the image. The first ...
twerpiebird's user avatar
0 votes
1 answer
261 views

Issue with Manually Setting ID in Spring Boot Integration Test with WebTestClient I am writing an integration test for my Spring Boot controller using WebTestClient. However, when I manually set the ...
ADITYA RAJ's user avatar
3 votes
1 answer
432 views

I have a Java Spring application that uses a PostgreSQL docker container for the tests. I would like to be able to see the SQL logs in that PostgreSQL container, but they do not show up. Can you ...
alexgbelov's user avatar
  • 3,191
1 vote
0 answers
622 views

I've got a spring-boot v3.2.5 app that runs successfully using testcontainers. I'm upgrading it to spring-boot v3.4.1. I create the postgres testcontainer like this. It also sets the property spring....
Kevin's user avatar
  • 2,011
1 vote
1 answer
249 views

I have the following ControllerIntegration test base class @TestInstance(Lifecycle.PER_CLASS) @AutoConfigureMockMvc @EnableConfigurationProperties @DirtiesContext(classMode = DirtiesContext.ClassMode....
Sydney's user avatar
  • 13
0 votes
0 answers
715 views

I want to run a a java TestContainer inside a non privileged container with a rootless podman. My docker commande to start it is like : $: docker run --security-opt seccomp=unconfined --security-opt ...
flywell's user avatar
  • 386
0 votes
1 answer
662 views

As a demo project, I use the following: https://github.com/testcontainers/testcontainers-java-spring-boot-quickstart, Information about Java and Docker versions is below: java -version openjdk version ...
user471011's user avatar
  • 7,400
0 votes
0 answers
190 views

Git Repo: https://github.com/SMHosseinM/demo I'm using Postgress testContainer to spin up a postgress container for my integration test. However, when running the test, the application context fails ...
Hossein's user avatar
  • 157
1 vote
0 answers
150 views

I'm working on a Kotlin project that uses Spring Boot, JOOQ for database code generation, and Testcontainers for integration testing with PostgreSQL. My build is managed with Gradle, and I am ...
Abdelmouheimen Trabelsi's user avatar
1 vote
0 answers
129 views

I wonder if there is a way to bootstrap a Docker environment when running tests with @Testcontainers. Right now when I run a test: @Testcontainers @SpringBootTest internal class MyTest() { @...
pixel's user avatar
  • 26.9k
0 votes
1 answer
436 views

I am trying to write an integration test for my Kafka consumer using @SpringBootTest and Testcontainers for the underlying infrastructure. My setup looks like this one: @Component @...
Daniel Pop's user avatar
1 vote
1 answer
2k views

I'm experiencing an issue with my integration tests using Testcontainers and the new @ServiceConnection annotation. I have an abstract class AbstractIntegrationTest which is extended by multiple test ...
Roger Frauca Cordoba's user avatar
2 votes
1 answer
142 views

I have a service 'S' which has the logic to generate a report and download it. It is written in spring-boot and java. This is consumed by another system 'B' that has the data in its database 'C' that ...
pinz's user avatar
  • 23
0 votes
0 answers
31 views

I have the following class that im using to start my application up locally with some containers (ommitted). For some reason i cant get it to pick up the local props file, it keeps picking up the ...
user1555190's user avatar
  • 3,409
1 vote
1 answer
457 views

I am failing to get the transactions to work in my basic spring data mongodb app. I've read articles and similar questions here and nothing seems to help. The test is being run with Testcontainers, ...
rafal.sz's user avatar
0 votes
2 answers
2k views

The problem is: When i try to use singleton-testcontainer, all my testclasses after first failed by assertions. It means, that even if i see in log that my scenarios was comlete success, Assertions ...
Yury's user avatar
  • 1
0 votes
1 answer
1k views

I'm trying to integrate Testcontainers in my spring boot app. I'm using Kafka Container to allow sending Kafka messages. The main issue is that when I send message to kafka correctly, I would like to ...
testtt's user avatar
  • 11
1 vote
0 answers
2k views

I have an old project that needed to be connected to ActiveMQ Artemis. Then I decided to write an integration test. However, I get an error at startup. I use Spring 2.5.14 and build.gradle. apply ...
skyho's user avatar
  • 1,973
0 votes
1 answer
1k views

I try to create JpaTest, for this I need a container with mariaDb. So I try create it: private static final String CONTAINER_IMAGE_NAME = TestcontainersConfiguration.getInstance() ....
AnnKont's user avatar
  • 516
1 vote
1 answer
467 views

I have a component where I have this code @PostConstruct public void initWeekMonthData() { testData = repository.findAllActiveRecords(); } Now I'm trying to write integration test ...
User's user avatar
  • 11
0 votes
1 answer
227 views

I have a testing workflow named "Test Project" set up in GitHub Actions, which includes a Maven test phase invoking a test class called RegistrationTest. This test class uses the ...
yaroslav96's user avatar
9 votes
1 answer
978 views

It started after I upgraded my SB application to 3.2.0. I initially thought there was something wrong with my spring context. So after a couple of days banging my head against the wall, I finally ...
Fabio Franco's user avatar
0 votes
0 answers
160 views

I have SpringBootTests that use org.testcontainer:postgres for integration tests. While thats very useful for tests that involve the database, it's quite useless when the database isn't needed. Let's ...
Frank Neblung's user avatar
2 votes
1 answer
672 views

We would like to utilize the enhanced Testcontainers support in Spring Boot 3.1 As a consequence, the Spring itself is now responsible for starting the containers, whereas previously we had full ...
David Kubecka's user avatar
1 vote
2 answers
3k views

I'm following this document to build a spring-boot application with org.springframework.boot:spring-boot-testcontainers dependency. I'm running the test in IntelliJ IDEA 2022.1 java version 17 org....
phuongnq1995's user avatar
  • 1,777
1 vote
1 answer
1k views

I am using multipleDatasources in my spring boot application where we connect to postgres and mysql. it is working as expected but when I want to integrate it with TestContainers in dev mode . I have ...
rajadilipkolli's user avatar
3 votes
4 answers
3k views

I am trying to use Spring Boot Tests with test containers. I wrote an abstract integration tests that all integration tests are using. @Testcontainers @Transactional @ActiveProfiles("test") @...
Barracuda's user avatar
  • 607
0 votes
2 answers
917 views

I am using Kafka from TestContainer, and @DynamicPropertySource does not override the KafkaProperties that I am using in the application code (src/main). KafkaProperties are load in the context even ...
kiuby_88's user avatar
  • 364
1 vote
2 answers
3k views

I'm trying to update my tests to use the latest support for Spring 3.1.4 for testcontainers, which replaces the @DynamicSource annotation with @ServiceConnection as per here . However, I'm getting ...
Francislainy Campos's user avatar
1 vote
1 answer
939 views

I'm having big troubles trying to test a kafka listener. The class is the following: @Component class KafkaListener( private val useCase: UseCase ) { @KafkaListener( topics = [&...
Mauricio Avendaño's user avatar
0 votes
1 answer
904 views

When I write a docker-compose file I can insert a logging section like so: logging: options: max-size: 10m max-file: "3" How can I congfigure my GenericContainer to have a logging ...
vab2048's user avatar
  • 1,297
1 vote
0 answers
274 views

We are trying to write integration tests for our usecase where we have 2 buckets in couchbase database and I am trying to create test container with those 2 buckets. I have something like new ...
Srikar's user avatar
  • 391
0 votes
1 answer
1k views

I'm in the process of exploring TestContainers with Spring Boot 3.0 for my Hello World application which has security-enabled endpoints. In the past, I relied on mocked tokens for unit testing ...
mitul bhatnagar's user avatar
1 vote
0 answers
4k views

I have following docker-compose file for local development: version: '3.4' services: samba: image: instantlinux/samba-dc:latest hostname: my.org environment: DOMAIN_ACTION: ...
gstackoverflow's user avatar
2 votes
2 answers
6k views

I am using new @ServiceConnection annotation to manage KafkaContainer in my tests and it works as expected - KafkaContainerConnectionDetails is used during auto configuration to override bootstrap ...
matejs's user avatar
  • 3,566
0 votes
1 answer
2k views

I have this integration test: @RunWith(SpringRunner.class) @SpringBootTest(classes = MySpringApplication.class, webEnvironment = DEFINED_PORT) public class UspControllerIT { @Test public void ...
italktothewind's user avatar
1 vote
0 answers
90 views

This is my application-it.yml file: spring: r2dbc: url: r2dbc:tc:mysql:///warehouse-db?TC_IMAGE_TAG=latest Here are my dependencies from pom.xml: <dependencies> <dependency> ...
fun_and_sun's user avatar
0 votes
1 answer
201 views

I want to run my Spring Boot application in the dev mode: My main (prod app): fun main(args: Array<String>) { runApplication<MyApp>(args = args, init = { addInitializers(...
pixel's user avatar
  • 26.9k
0 votes
2 answers
472 views

I have a Spring Boot application: @SpringBootApplication class MyApp fun main(args: Array<String>) { val initConfig: SpringApplication.() -> Unit = { addInitializers(...
pixel's user avatar
  • 26.9k