Build, run tests, package and deploy #8
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Tests Klass Forvaltning | |
| run-name: "Build, run tests, package and deploy" | |
| permissions: | |
| contents: read | |
| packages: read | |
| on: | |
| push: | |
| branches: | |
| - main | |
| paths: | |
| - klass-forvaltning | |
| - .github/workflows/tests-klass-forvaltning.yml | |
| pull_request: | |
| paths: | |
| - klass-forvaltning | |
| - .github/workflows/tests-klass-forvaltning.yml | |
| jobs: | |
| build-klass-forvaltning: | |
| runs-on: ubuntu-latest | |
| permissions: | |
| contents: read | |
| packages: read | |
| steps: | |
| - uses: actions/checkout@v6 | |
| - name: Set up JDK 1.8 | |
| uses: actions/setup-java@v4 | |
| with: | |
| distribution: 'zulu' | |
| java-version: '8' | |
| cache: maven | |
| # Build only klass-forvaltning with JDK 1.8 | |
| - name: Build and test Klass Forvaltning | |
| working-directory: klass-forvaltning | |
| run: mvn --batch-mode --update-snapshots package -Djava.version=1.8 -am | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |