Skip to content

scripts/initializr: sync template with cn1app-archetype#5093

Merged
shai-almog merged 1 commit into
masterfrom
initializr-junit-jupiter-and-cn1-plugin-sync
May 29, 2026
Merged

scripts/initializr: sync template with cn1app-archetype#5093
shai-almog merged 1 commit into
masterfrom
initializr-junit-jupiter-and-cn1-plugin-sync

Conversation

@shai-almog
Copy link
Copy Markdown
Collaborator

Summary

The initializr-served project template had drifted from maven/cn1app-archetype/src/main/resources/archetype-resources/, leaving freshly generated projects in a broken state for tests and missing two CN1 plugin features.

  • common/pom.xml and javase/pom.xml were missing the org.junit.jupiter:junit-jupiter:5.9.3 test-scope dep. Because the generated sample test (common/src/test/java/.../GreetingFormTest.java) imports org.junit.jupiter.api.Test, mvn test from a freshly generated project fails at testCompile in common with package org.junit.jupiter.api does not exist.
  • common/pom.xml was missing the codenameone-maven-plugin transcode-svg execution (build-time SVG → GeneratedSVGImage transcoder) and the process-annotations goal on the cn1-process-classes execution (@Route dispatcher generation). Both are present in the archetype.

This brings the initializr template in line with the archetype on those points.

Test plan

  • Generate a fresh project from initializr after this lands, verify common/src/test/java JUnit 5 sample compiles and the IDE gutter run-arrow on GreetingFormTest resolves all imports.
  • Drop an SVG into common/src/main/svg/ and confirm a GeneratedSVGImage subclass is produced during process-sources.
  • Add a class annotated with @Route and confirm the dispatcher class is generated during process-classes.

🤖 Generated with Claude Code

The initializr-served project template drifted from the
cn1app-archetype:

- common/pom.xml and javase/pom.xml both lacked the
  org.junit.jupiter:junit-jupiter:5.9.3 test-scope dependency, so the
  JUnit 5 test that ships in common/src/test/java fails to compile
  ("package org.junit.jupiter.api does not exist") in any generated
  project.
- common/pom.xml was missing the codenameone-maven-plugin
  transcode-svg execution and the process-annotations goal on
  cn1-process-classes, so generated apps had no SVG transcoding and
  no @route dispatcher generation.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@github-actions
Copy link
Copy Markdown
Contributor

Cloudflare Preview

@shai-almog shai-almog merged commit 84d58b2 into master May 29, 2026
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant