-
Notifications
You must be signed in to change notification settings - Fork 0
Add CI workflow to test/build PrototypeMachinery and ModernBackend #1
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change | ||||||||
|---|---|---|---|---|---|---|---|---|---|---|
| @@ -0,0 +1,52 @@ | ||||||||||
| name: Build Mods | ||||||||||
|
|
||||||||||
| on: | ||||||||||
| push: | ||||||||||
| branches: ["master"] | ||||||||||
| pull_request: | ||||||||||
| workflow_dispatch: | ||||||||||
|
|
||||||||||
| permissions: | ||||||||||
| contents: read | ||||||||||
|
|
||||||||||
| jobs: | ||||||||||
| build: | ||||||||||
| runs-on: ubuntu-latest | ||||||||||
| steps: | ||||||||||
| - name: Checkout | ||||||||||
| uses: actions/checkout@v4 | ||||||||||
|
|
||||||||||
| - name: Setup Java | ||||||||||
| uses: actions/setup-java@v4 | ||||||||||
| with: | ||||||||||
| distribution: temurin | ||||||||||
| java-version: 21 | ||||||||||
| cache: gradle | ||||||||||
|
|
||||||||||
|
||||||||||
| - name: Ensure Gradle wrappers are executable | |
| run: chmod +x gradlew modern-backend/gradlew |
Copilot
AI
Feb 4, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The modern-backend directory does not have a src/test directory or any test source files. Running ./gradlew test will likely succeed but not actually test anything meaningful. Consider either removing the test step for Modern Backend, or adding test sources if test coverage is needed for this module.
Copilot
AI
Feb 4, 2026
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The Modern Backend build requires the main PrototypeMachinery jar to exist in ../build/libs before it can compile (see modern-backend/build.gradle lines 130-151 and 294-303). The build order in this workflow is correct since PrototypeMachinery is built before Modern Backend, but this dependency could be made more explicit and robust by checking that the jar exists or by failing earlier with a clear message if the PrototypeMachinery build step is skipped or fails.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The main PrototypeMachinery build.gradle.kts specifies a Java 8 toolchain with Azul vendor preference (lines 62-65), but the workflow only sets up Java 21 via actions/setup-java. While GitHub Actions ubuntu-latest runners typically include multiple Java versions, and Gradle's toolchain will use any available Java 8 JDK if Azul is not available, this could lead to inconsistent builds. Consider either: (1) adding org.gradle.java.installations.auto-download=true to the root gradle.properties to enable automatic toolchain provisioning, or (2) setting up Java 8 explicitly in the workflow using a matrix strategy with setup-java to ensure the preferred Azul JDK 8 is available.