Skip to content

Commit 8dd6ea8

Browse files
yonatankarpclaude
andcommitted
fix(kotlin-spring): remove SB4+Jackson2 test since SB4 unconditionally implies Jackson 3
Spring Boot 4 ships with Jackson 3 — there is no supported SB4+Jackson2 combination, so the test was asserting an invalid scenario. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent f44c9a1 commit 8dd6ea8

1 file changed

Lines changed: 0 additions & 32 deletions

File tree

modules/openapi-generator/src/test/java/org/openapitools/codegen/kotlin/spring/KotlinSpringServerCodegenTest.java

Lines changed: 0 additions & 32 deletions
Original file line numberDiff line numberDiff line change
@@ -4873,38 +4873,6 @@ public void shouldGenerateSpringBoot4PomWithJackson3Deps() throws IOException {
48734873
assertFileNotContains(pomPath, "com.fasterxml.jackson.module");
48744874
}
48754875

4876-
@Test
4877-
public void shouldGenerateSpringBoot4PomWithJackson2Deps() throws IOException {
4878-
File output = Files.createTempDirectory("test").toFile().getCanonicalFile();
4879-
output.deleteOnExit();
4880-
String outputPath = output.getAbsolutePath().replace('\\', '/');
4881-
4882-
final OpenAPI openAPI = TestUtils.parseFlattenSpec("src/test/resources/3_0/petstore.yaml");
4883-
final KotlinSpringServerCodegen codegen = new KotlinSpringServerCodegen();
4884-
codegen.setOpenAPI(openAPI);
4885-
codegen.setOutputDir(output.getAbsolutePath());
4886-
4887-
codegen.additionalProperties().put(KotlinSpringServerCodegen.USE_SPRING_BOOT4, "true");
4888-
codegen.additionalProperties().put(AbstractKotlinCodegen.USE_JACKSON_3, "false");
4889-
codegen.additionalProperties().put(DOCUMENTATION_PROVIDER, DocumentationProvider.NONE.toCliOptValue());
4890-
codegen.additionalProperties().put(ANNOTATION_LIBRARY, AnnotationLibrary.NONE.toCliOptValue());
4891-
4892-
ClientOptInput input = new ClientOptInput();
4893-
input.openAPI(openAPI);
4894-
input.config(codegen);
4895-
4896-
DefaultGenerator generator = new DefaultGenerator();
4897-
generator.setGenerateMetadata(false);
4898-
generator.opts(input).generate();
4899-
4900-
Path pomPath = Paths.get(outputPath + "/pom.xml");
4901-
assertFileContains(pomPath, "4.0.1");
4902-
assertFileContains(pomPath, "com.fasterxml.jackson.dataformat");
4903-
assertFileContains(pomPath, "jackson-datatype-jsr310");
4904-
assertFileNotContains(pomPath, "tools.jackson.dataformat");
4905-
assertFileNotContains(pomPath, "tools.jackson.module");
4906-
}
4907-
49084876
@Test
49094877
public void shouldDefaultToJackson3WhenSpringBoot4Enabled() throws IOException {
49104878
File output = Files.createTempDirectory("test").toFile().getCanonicalFile();

0 commit comments

Comments
 (0)