Skip to content

Merge pull request #2 from y-ok/postgreSQL #12

Merge pull request #2 from y-ok/postgreSQL

Merge pull request #2 from y-ok/postgreSQL #12

Workflow file for this run

name: CI
on:
push:
branches:
- main
pull_request:
workflow_dispatch:
permissions:
contents: read
id-token: write
jobs:
test-and-coverage:
runs-on: ubuntu-latest
timeout-minutes: 90
strategy:
fail-fast: false
matrix:
java: [ '11', '17', '21', '25' ]
env:
DOCKER_HOST: unix:///var/run/docker.sock
TESTCONTAINERS_DOCKER_SOCKET_OVERRIDE: /var/run/docker.sock
TESTCONTAINERS_RYUK_DISABLED: false
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Set up JDK ${{ matrix.java }}
uses: actions/setup-java@v4
with:
distribution: temurin
java-version: ${{ matrix.java }}
cache: maven
- name: Verify Docker
run: docker info
- name: Run tests (including Testcontainers)
run: mvn -B clean test
- name: Upload JaCoCo XML as artifact
if: always() && matrix.java == '21'
uses: actions/upload-artifact@v4
with:
name: jacoco-report
path: target/site/jacoco/jacoco.xml
if-no-files-found: warn
- name: Upload coverage to Codecov
if: always() && matrix.java == '21'
uses: codecov/codecov-action@v5
with:
files: target/site/jacoco/jacoco.xml
flags: unittests,integration
fail_ci_if_error: false
verbose: true