Skip to content

Commit c2359fd

Browse files
committed
update Spring Test Profiler
1 parent eddee47 commit c2359fd

3 files changed

Lines changed: 5 additions & 6 deletions

File tree

pom.xml

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -132,12 +132,7 @@
132132
<dependency>
133133
<groupId>digital.pragmatech.testing</groupId>
134134
<artifactId>spring-test-profiler</artifactId>
135-
<version>0.0.14</version>
136-
<scope>test</scope>
137-
</dependency>
138-
<dependency>
139-
<groupId>com.fasterxml.jackson.datatype</groupId>
140-
<artifactId>jackson-datatype-jsr310</artifactId>
135+
<version>0.0.15</version>
141136
<scope>test</scope>
142137
</dependency>
143138

src/test/java/de/rieckpil/blog/ShelfieApplicationIT.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,9 @@
33
import org.junit.jupiter.api.Test;
44
import org.springframework.boot.test.context.SpringBootTest;
55
import org.springframework.context.annotation.Import;
6+
import org.springframework.test.context.TestPropertySource;
67

8+
@TestPropertySource(properties = "foo.bar=42")
79
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
810
@Import(LocalDevTestcontainerConfig.class)
911
class ShelfieApplicationIT {

src/test/java/de/rieckpil/blog/examples/chapter3/BookshelfShelfieApplicationIT.java

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@
1818
import org.springframework.http.HttpStatus;
1919
import org.springframework.http.MediaType;
2020
import org.springframework.http.ResponseEntity;
21+
import org.springframework.test.context.ActiveProfiles;
2122
import org.springframework.test.context.DynamicPropertyRegistry;
2223
import org.springframework.test.context.DynamicPropertySource;
2324
import org.testcontainers.junit.jupiter.Container;
@@ -29,6 +30,7 @@
2930
import static com.github.tomakehurst.wiremock.client.WireMock.urlEqualTo;
3031
import static org.assertj.core.api.Assertions.assertThat;
3132

33+
@ActiveProfiles("other-test-profile") // show difference in Spring Test Profiler
3234
@AutoConfigureTestRestTemplate
3335
@Testcontainers
3436
@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)

0 commit comments

Comments
 (0)