From 1cba3777e6edf0a6557d91b651e96a9392369db6 Mon Sep 17 00:00:00 2001 From: Tim Van Wassenhove Date: Fri, 29 Mar 2024 00:07:22 +0100 Subject: [PATCH 1/6] ci: attempt to capture test results and upload them --- .github/workflows/test_suite.yml | 20 +++++++++++++++++++- 1 file changed, 19 insertions(+), 1 deletion(-) diff --git a/.github/workflows/test_suite.yml b/.github/workflows/test_suite.yml index 161726c..f8f10b9 100644 --- a/.github/workflows/test_suite.yml +++ b/.github/workflows/test_suite.yml @@ -16,9 +16,27 @@ jobs: with: submodules: recursive - uses: actions-rust-lang/setup-rust-toolchain@v1 + - name: Start minio run: ./ci/minio_start.sh - - run: cargo test --all-features + + - run: cargo test --all-features -- -Z unstable-options --format json --report-time | tee results.json + + - name: Prepare junit report + id: cargo_reporter + uses: innoq/action-cargo-test-report + with: + cargo-test-report-json: 'results.json' + + - name: Publish Test Report + uses: mikepenz/action-junit-report@main + if: always() # always run even if the previous step fails + with: + check_name: Test Report + fail_on_failure: true + require_tests: true + summary: ${{ steps.cargo_reporter.outputs.summary }} + - name: Stop minio run: ./ci/minio_stop.sh From a2acc5de843e5945a30bfee4f8d5962fd02439db Mon Sep 17 00:00:00 2001 From: Tim Van Wassenhove Date: Fri, 29 Mar 2024 07:36:22 +0100 Subject: [PATCH 2/6] ci: use nightly --- .github/workflows/test_suite.yml | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/.github/workflows/test_suite.yml b/.github/workflows/test_suite.yml index f8f10b9..d6b4610 100644 --- a/.github/workflows/test_suite.yml +++ b/.github/workflows/test_suite.yml @@ -16,18 +16,15 @@ jobs: with: submodules: recursive - uses: actions-rust-lang/setup-rust-toolchain@v1 - + with: + toolchain: nightly - name: Start minio run: ./ci/minio_start.sh - - run: cargo test --all-features -- -Z unstable-options --format json --report-time | tee results.json - - name: Prepare junit report - id: cargo_reporter uses: innoq/action-cargo-test-report with: cargo-test-report-json: 'results.json' - - name: Publish Test Report uses: mikepenz/action-junit-report@main if: always() # always run even if the previous step fails @@ -36,7 +33,6 @@ jobs: fail_on_failure: true require_tests: true summary: ${{ steps.cargo_reporter.outputs.summary }} - - name: Stop minio run: ./ci/minio_stop.sh From 3a1ac12c16e672005bb0039222a022f53f04b48d Mon Sep 17 00:00:00 2001 From: Tim Van Wassenhove Date: Fri, 29 Mar 2024 07:47:20 +0100 Subject: [PATCH 3/6] ci: specify versions --- .github/workflows/test_suite.yml | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/.github/workflows/test_suite.yml b/.github/workflows/test_suite.yml index d6b4610..c8aab1c 100644 --- a/.github/workflows/test_suite.yml +++ b/.github/workflows/test_suite.yml @@ -22,11 +22,12 @@ jobs: run: ./ci/minio_start.sh - run: cargo test --all-features -- -Z unstable-options --format json --report-time | tee results.json - name: Prepare junit report - uses: innoq/action-cargo-test-report + id: cargo_reporter + uses: innoq/action-cargo-test-report@v1 with: cargo-test-report-json: 'results.json' - name: Publish Test Report - uses: mikepenz/action-junit-report@main + uses: mikepenz/action-junit-report@v4 if: always() # always run even if the previous step fails with: check_name: Test Report From ae280da0bb94417bbf9e69b9c22baaafb6fb4d2e Mon Sep 17 00:00:00 2001 From: Tim Van Wassenhove Date: Fri, 29 Mar 2024 07:50:47 +0100 Subject: [PATCH 4/6] ci: do not group prs --- .github/renovate.json | 8 -------- 1 file changed, 8 deletions(-) diff --git a/.github/renovate.json b/.github/renovate.json index 19d07a2..8bb6246 100644 --- a/.github/renovate.json +++ b/.github/renovate.json @@ -7,16 +7,8 @@ "matchPackagePatterns": [ "*" ], - "groupName": "all dependencies", - "groupSlug": "all", "automerge": true } ], - "groupName": "all dependencies", - "separateMajorMinor": false, - "groupSlug": "all", - "lockFileMaintenance": { - "enabled": false - }, "dependencyDashboard": true } From 3d8759d26ff36df06bbca6fd553e3620425ad2f9 Mon Sep 17 00:00:00 2001 From: Tim Van Wassenhove Date: Fri, 29 Mar 2024 08:00:38 +0100 Subject: [PATCH 5/6] ci: only annotate tests results --- .github/workflows/test_suite.yml | 1 + 1 file changed, 1 insertion(+) diff --git a/.github/workflows/test_suite.yml b/.github/workflows/test_suite.yml index c8aab1c..dc827af 100644 --- a/.github/workflows/test_suite.yml +++ b/.github/workflows/test_suite.yml @@ -33,6 +33,7 @@ jobs: check_name: Test Report fail_on_failure: true require_tests: true + annotate_only: true summary: ${{ steps.cargo_reporter.outputs.summary }} - name: Stop minio run: ./ci/minio_stop.sh From adca8bb45b247aff0800eab15e7aa2ac401109c0 Mon Sep 17 00:00:00 2001 From: Tim Van Wassenhove Date: Fri, 29 Mar 2024 08:56:10 +0100 Subject: [PATCH 6/6] ci: attempt to trigger test run only once --- .github/workflows/test_suite.yml | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/.github/workflows/test_suite.yml b/.github/workflows/test_suite.yml index dc827af..050e18e 100644 --- a/.github/workflows/test_suite.yml +++ b/.github/workflows/test_suite.yml @@ -1,7 +1,15 @@ name: "Test Suite" on: push: + branches-ignore: + - 'dependabot/**' #avoid duplicates: only run the PR, not the push + - 'renovate/**' #avoid duplicates: only run the PR, not the push + - 'gh-pages' #github pages do not trigger all tests + tags-ignore: + - 'v*' #avoid rerun existing commit on release pull_request: + branches: + - 'main' concurrency: group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }} @@ -9,6 +17,7 @@ concurrency: jobs: test: + if: (github.event_name != 'pull_request' && ! github.event.pull_request.head.repo.fork) || (github.event_name == 'pull_request' && (github.event.pull_request.head.repo.fork || startsWith(github.head_ref, 'dependabot/') || startsWith(github.head_ref, 'renovate/'))) name: cargo test runs-on: ubuntu-latest steps: @@ -40,6 +49,7 @@ jobs: # Check formatting with rustfmt formatting: + if: (github.event_name != 'pull_request' && ! github.event.pull_request.head.repo.fork) || (github.event_name == 'pull_request' && (github.event.pull_request.head.repo.fork || startsWith(github.head_ref, 'dependabot/') || startsWith(github.head_ref, 'renovate/'))) name: cargo fmt runs-on: ubuntu-latest steps: @@ -52,6 +62,7 @@ jobs: uses: actions-rust-lang/rustfmt@v1 lint: + if: (github.event_name != 'pull_request' && ! github.event.pull_request.head.repo.fork) || (github.event_name == 'pull_request' && (github.event.pull_request.head.repo.fork || startsWith(github.head_ref, 'dependabot/') || startsWith(github.head_ref, 'renovate/'))) name: cargo clippy runs-on: ubuntu-latest steps: