From ba978df5785c0fc63fc9f81405207254ba1ecec5 Mon Sep 17 00:00:00 2001 From: oech3 <79379754+oech3@users.noreply.github.com> Date: Sun, 4 Oct 2026 13:53:43 +0900 Subject: [PATCH] fuzzing.yml: use prebuilt cargo-fuzz for faster CI --- .github/workflows/fuzzing.yml | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/.github/workflows/fuzzing.yml b/.github/workflows/fuzzing.yml index 6c9e010..a218146 100644 --- a/.github/workflows/fuzzing.yml +++ b/.github/workflows/fuzzing.yml @@ -26,14 +26,16 @@ jobs: steps: - uses: actions/checkout@v7 - name: Install `cargo-fuzz` - run: | - cargo install cargo-fuzz --locked + uses: taiki-e/install-action@v2 + with: + tool: cargo-fuzz - uses: Swatinem/rust-cache@v2 with: shared-key: "cargo-fuzz-cache-key" cache-directories: "fuzz/target" - name: Run `cargo-fuzz build` - run: cargo fuzz build + # https://github.com/rust-fuzz/cargo-fuzz/issues/398 + run: cargo fuzz build --target host-tuple fuzz-run: needs: fuzz-build @@ -54,8 +56,9 @@ jobs: steps: - uses: actions/checkout@v7 - name: Install `cargo-fuzz` - run: | - cargo install cargo-fuzz --locked + uses: taiki-e/install-action@v2 + with: + tool: cargo-fuzz - uses: Swatinem/rust-cache@v2 with: shared-key: "cargo-fuzz-cache-key" @@ -70,7 +73,7 @@ jobs: shell: bash continue-on-error: ${{ !matrix.test-target.should_pass }} run: | - cargo fuzz run ${{ matrix.test-target.name }} -- -max_total_time=${{ env.RUN_FOR }} -detect_leaks=0 + cargo fuzz run --target host-tuple ${{ matrix.test-target.name }} -- -max_total_time=${{ env.RUN_FOR }} -detect_leaks=0 - name: Save Corpus Cache uses: actions/cache/save@v6 with: