Skip to content

Commit 5ac3c84

Browse files
committed
test(spring-boot): Move the Boot 3 WebFlux sample's tests into the module
Adds an integrationTestWebflux suite to sentry-spring-boot-jakarta. It runs a reactive app without the servlet stack, so Spring Boot starts a WebFlux server, and ports the WebFlux sample's Person, DistributedTracing, Todo and GraphQL tests. The sample's Cache and Metrics tests were copies of the servlet ones and don't depend on the web stack, so the integrationTest suite already covers them. The WebFlux sample has no system tests left, so it comes off the system-test runner, the backend workflow and the Spring Boot 3 matrix, which now runs the new suite. integrationTests includes it too. Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
1 parent cac3297 commit 5ac3c84

21 files changed

Lines changed: 484 additions & 539 deletions

File tree

‎.github/workflows/spring-boot-3-matrix.yml‎

Lines changed: 1 addition & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -71,8 +71,6 @@ jobs:
7171
- name: Build sample artifacts
7272
run: |
7373
./gradlew \
74-
:sentry-samples:sentry-samples-spring-boot-webflux-jakarta:bootJar \
75-
:sentry-samples:sentry-samples-spring-boot-webflux-jakarta:testClasses \
7674
:sentry-samples:sentry-samples-spring-boot-jakarta-opentelemetry:bootJar \
7775
:sentry-samples:sentry-samples-spring-boot-jakarta-opentelemetry:testClasses \
7876
:sentry-samples:sentry-samples-spring-boot-jakarta-opentelemetry-noagent:bootJar \
@@ -85,16 +83,10 @@ jobs:
8583
run: |
8684
./gradlew \
8785
:sentry-spring-boot-jakarta:integrationTest \
86+
:sentry-spring-boot-jakarta:integrationTestWebflux \
8887
:sentry-spring-boot-jakarta:integrationTestLog4j2 \
8988
:sentry-spring-boot-jakarta:integrationTestOtelAgent
9089
91-
- name: Test sentry-samples-spring-boot-webflux-jakarta
92-
run: |
93-
python3 test/system-test-runner.py test \
94-
--module "sentry-samples-spring-boot-webflux-jakarta" \
95-
--agent false \
96-
--auto-init "true"
97-
9890
- name: Test sentry-samples-spring-boot-jakarta-opentelemetry agent init true
9991
run: |
10092
python3 test/system-test-runner.py test \

‎.github/workflows/system-tests-backend.yml‎

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,9 +34,6 @@ jobs:
3434
- sample: "sentry-samples-spring-boot-opentelemetry"
3535
agent: "true"
3636
agent-auto-init: "false"
37-
- sample: "sentry-samples-spring-boot-webflux-jakarta"
38-
agent: "false"
39-
agent-auto-init: "true"
4037
- sample: "sentry-samples-spring-boot-webflux"
4138
agent: "false"
4239
agent-auto-init: "true"

‎build.gradle.kts‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -225,6 +225,7 @@ tasks.register("integrationTests") {
225225
dependsOn(
226226
":sentry-spring-boot:integrationTest",
227227
":sentry-spring-boot-jakarta:integrationTest",
228+
":sentry-spring-boot-jakarta:integrationTestWebflux",
228229
":sentry-spring-boot-jakarta:integrationTestLog4j2",
229230
":sentry-spring-boot-jakarta:integrationTestOtelAgent",
230231
":sentry-spring-boot-4:integrationTest",

‎sentry-samples/sentry-samples-spring-boot-webflux-jakarta/build.gradle.kts‎

Lines changed: 0 additions & 31 deletions
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,6 @@ plugins {
66
alias(libs.plugins.spring.dependency.management)
77
alias(libs.plugins.kotlin.jvm)
88
alias(libs.plugins.kotlin.spring)
9-
id("io.sentry.systemtest")
109
}
1110

1211
group = "io.sentry.sample.spring-boot-webflux-jakarta"
@@ -38,40 +37,10 @@ dependencies {
3837
// cache tracing
3938
implementation(libs.springboot3.starter.cache)
4039
implementation(libs.caffeine)
41-
42-
testImplementation(kotlin(Config.kotlinStdLib))
43-
testImplementation(projects.sentrySystemTestSupport)
44-
testImplementation(libs.apollo3.kotlin)
45-
testImplementation(libs.kotlin.test.junit)
46-
testImplementation(libs.slf4j2.api)
47-
testImplementation(libs.springboot3.starter.test) {
48-
exclude(group = "org.junit.vintage", module = "junit-vintage-engine")
49-
}
50-
testImplementation("ch.qos.logback:logback-classic:1.5.16")
51-
testImplementation("ch.qos.logback:logback-core:1.5.16")
5240
}
5341

5442
tasks.withType<KotlinCompile>().configureEach {
5543
kotlin {
5644
compilerOptions.freeCompilerArgs = listOf("-Xjsr305=strict")
5745
}
5846
}
59-
60-
tasks.register<Test>("systemTest").configure {
61-
group = "verification"
62-
description = "Runs the System tests"
63-
64-
val test = project.extensions.getByType<SourceSetContainer>()["test"]
65-
testClassesDirs = test.output.classesDirs
66-
classpath = test.runtimeClasspath
67-
68-
maxParallelForks = 1
69-
70-
filter { includeTestsMatching("io.sentry.systemtest*") }
71-
}
72-
73-
tasks.named("test").configure {
74-
require(this is Test)
75-
76-
filter { excludeTestsMatching("io.sentry.systemtest.*") }
77-
}

‎sentry-samples/sentry-samples-spring-boot-webflux-jakarta/src/test/kotlin/io/sentry/DummyTest.kt‎

Lines changed: 0 additions & 12 deletions
This file was deleted.

‎sentry-samples/sentry-samples-spring-boot-webflux-jakarta/src/test/kotlin/io/sentry/systemtest/CacheSystemTest.kt‎

Lines changed: 0 additions & 51 deletions
This file was deleted.

‎sentry-samples/sentry-samples-spring-boot-webflux-jakarta/src/test/kotlin/io/sentry/systemtest/DistributedTracingSystemTest.kt‎

Lines changed: 0 additions & 197 deletions
This file was deleted.

0 commit comments

Comments
 (0)