Skip to main content
The 2024 Developer Survey results are live! See the results

Questions tagged [spring-boot-testcontainers]

The tag has no usage guidance.

spring-boot-testcontainers
0 votes
0 answers
17 views

record content lost with jooq 18 + spring boot 3.2 + jpa annotations [updated]

I'm working on a small tutorial project that will have both jooq and various spring database implementations. The idea is to demonstrate a core module with nearly everything plus minimal, easily ...
bgiles's user avatar
  • 1,210
-2 votes
0 answers
19 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
0 answers
31 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
0 votes
0 answers
46 views

java.lang.ClassNotFoundException: jakarta.servlet.ServletConnection: Spring Boot and Jetty

Our project uses Spring Boot 3 and Jetty 11. As detailed here, there are some compatibility issues. So the jakarta.servlet-api:5.0.0 has been added explicitly. <dependency> <artifactId>...
Ramanujan R's user avatar
  • 1,711
0 votes
0 answers
66 views

Testcontainers, getting error while pulling image testcontainers/ryuk:0.3.4

I am working on testcontainers with spring boot. Until last week, it was working fine and all of a sudden i started getting below error when running test cases. It seems when test container try to ...
Bharathi Palanichamy's user avatar
0 votes
0 answers
23 views

Overriding Spring datasource properties for integrationTest with testcontainer DB credentials in SpringBoot application

I have setup a gradle Spring boot application where I am trying to execute the build process using a testcontainer. Here is what I wanted to achieve when I run .\gradlew clean build Start a MySql ...
Debapriya Patra's user avatar
1 vote
0 answers
38 views

A way to bootstrap Docker environment when running Testcontainers tests?

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
  • 26k
0 votes
1 answer
62 views

@KafkaListener with containerFactory is not triggered in @SpringBootTest

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
0 votes
1 answer
152 views

Issue with Testcontainers @ServiceConnection in AbstractIntegrationTest When Running Multiple Test Classes

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
27 views

Can we use mocking frameworks for load testing or should we create interfaces to inject dummy data into a class?

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
19 views

spring specify location of propepties file

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,131
1 vote
1 answer
70 views

@Transactional in Spring Data MongoDB (+testcontainers)

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
184 views

When i try to test with Testcontainers more than one TestClass, others always failed

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
464 views

Spring Testcontainers with kafka producer

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
0 votes
0 answers
476 views

cannot access org.junit.rules.TestRule withUser("testcontainers") (an integration test for ActiveMQ Artemis)

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,835

15 30 50 per page