Add GitHub Actions for Maven setup, JUnit reporting, and SonarCloud analysis. Update README with SonarCloud badges, embed assets, and document breaking changes. Refactor APIs with paging support, add model class tests, and improve error messages and code quality. Fix #13 and fix #15.
This commit is contained in:
@@ -0,0 +1,35 @@
|
||||
name: Publish JUnit Report (Short Names)
|
||||
description: Normalize JUnit XML report names and publish a summary-only test report.
|
||||
inputs:
|
||||
token:
|
||||
description: GitHub token for creating the check run.
|
||||
required: true
|
||||
report-name:
|
||||
description: Name shown for the test report.
|
||||
required: false
|
||||
default: Summary of JUnit Tests
|
||||
|
||||
runs:
|
||||
using: composite
|
||||
steps:
|
||||
- name: Normalize JUnit report names
|
||||
shell: bash
|
||||
run: |
|
||||
mkdir -p junit-short
|
||||
shopt -s globstar nullglob
|
||||
for f in **/target/*-reports/TEST-*.xml; do
|
||||
base="$(basename "$f")"
|
||||
short="${base#TEST-}"
|
||||
short="${short%.xml}"
|
||||
cp "$f" "junit-short/${short}"
|
||||
done
|
||||
|
||||
- name: Publish Test Report
|
||||
uses: dorny/test-reporter@v2
|
||||
with:
|
||||
token: ${{ inputs.token }}
|
||||
name: ${{ inputs.report-name }}
|
||||
path: "*"
|
||||
reporter: java-junit
|
||||
only-summary: true
|
||||
working-directory: "junit-short"
|
||||
@@ -0,0 +1,29 @@
|
||||
name: "Setup Maven with GitHub Packages"
|
||||
|
||||
description: "Sets up JDK, caches Maven dependencies, and configures GitHub Packages for Maven repositories."
|
||||
|
||||
inputs:
|
||||
java-version:
|
||||
description: "Java version to install"
|
||||
default: "17"
|
||||
required: true
|
||||
java-distribution:
|
||||
description: "Java distribution to use"
|
||||
default: "corretto"
|
||||
|
||||
runs:
|
||||
using: "composite"
|
||||
steps:
|
||||
- name: Set up JDK
|
||||
uses: actions/setup-java@v4
|
||||
with:
|
||||
distribution: ${{ inputs.java-distribution }}
|
||||
java-version: ${{ inputs.java-version }}
|
||||
|
||||
- name: Cache Maven Repository
|
||||
uses: actions/cache@v4
|
||||
with:
|
||||
path: ~/.m2/repository
|
||||
key: ${{ runner.os }}-maven-${{ hashFiles('**/pom.xml') }}
|
||||
restore-keys: |
|
||||
${{ runner.os }}-maven-
|
||||
Reference in New Issue
Block a user