From 93e220f5362a35ded1301c9a00ab993f6ba67490 Mon Sep 17 00:00:00 2001 From: "Florine W. Dekker" Date: Fri, 1 Dec 2023 18:15:24 +0100 Subject: [PATCH] Rewrite CI scripts --- .github/workflows/ci.yml | 55 ++++++++++++++++++++++++++++------------ CHANGELOG.md | 4 +++ 2 files changed, 43 insertions(+), 16 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index cd344f06a..e9b424bee 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -13,32 +13,55 @@ on: - '.github/img/**' jobs: - build: - runs-on: ${{ matrix.os }} - strategy: - matrix: - os: [ ubuntu-latest, windows-latest ] + test-linux: + runs-on: ubuntu-latest steps: - - uses: actions/checkout@v3 - - uses: actions/setup-java@v3 + - name: Checkout + uses: actions/checkout@v4 + - name: Set up Java + uses: actions/setup-java@v4 with: distribution: 'temurin' java-version: '17' - cache: 'gradle' - - name: Run checks (Ubuntu) - if: matrix.os == 'ubuntu-latest' + - name: Set up Gradle + uses: gradle/gradle-build-action@v2 + - name: Run tests run: | - chmod +x ./gradlew - sudo apt install -y xvfb xvfb-run --auto-servernum ./gradlew --no-daemon check ./gradlew --stop - - name: Run checks (Windows) - if: matrix.os == 'windows-latest' + - name: Store coverage report + uses: actions/upload-artifact@v3 + with: + name: coverage + path: build/reports/kover/report.xml + + test-windows: + runs-on: windows-latest + steps: + - name: Checkout + uses: actions/checkout@v4 + - name: Set up Java + uses: actions/setup-java@v4 + with: + distribution: 'temurin' + java-version: '17' + - name: Set up Gradle + uses: gradle/gradle-build-action@v2 + - name: Run tests run: | ./gradlew --no-daemon check ./gradlew --stop - - uses: codecov/codecov-action@v3 - if: success() && matrix.os == 'ubuntu-latest' + + upload-coverage: + needs: [ test-linux, test-windows ] + runs-on: ubuntu-latest + steps: + - name: Load coverage report + uses: actions/download-artifact@v3 + with: + name: coverage + - name: Upload coverage report + uses: codecov/codecov-action@v3 with: fail_ci_if_error: true files: build/reports/kover/report.xml diff --git a/CHANGELOG.md b/CHANGELOG.md index 2d5f2123a..a4a5cc0fc 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,8 @@ # Changelog +## Unreleased +(empty) + + ## 3.0.0 -- 2023-11-17 This release brings a major overhaul of how data is generated, allowing you to create your own data types such as IP addresses or entire JSON objects.