Skip to content

Commit

Permalink
Remove gitlab-ci and migrate fuzz job to GHA (#1996)
Browse files Browse the repository at this point in the history
  • Loading branch information
smiasojed authored Nov 17, 2023
1 parent cd0670a commit 99370f1
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 571 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -600,3 +600,50 @@ jobs:
needs: [examples-docs, examples-contract-build, examples-test]
uses: ./.github/workflows/measurements.yml

# fuzz

fuzz:
# Temporarily disabled until https://github.com/paritytech/ink/issues/1374
# is fixed.
if: >
false &&
github.event_name == 'push' &&
github.ref == 'refs/heads/master'
runs-on: ubuntu-latest
needs: [set-image, measurements]
defaults:
run:
shell: bash
container:
image: ${{ needs.set-image.outputs.IMAGE }}
strategy:
fail-fast: false
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 100

- name: Cache
uses: Swatinem/rust-cache@v2
with:
cache-directories: ${{ env.CARGO_TARGET_DIR }}

- name: Rust Info
uses: ./.github/rust-info

- name: Fuzz
env:
QUICKCHECK_TESTS: 5000
run: |
# We fuzz-test only crates which possess the `ink-fuzz-tests` feature
all_tests_passed=0
ALL_CRATES="${PURELY_STD_CRATES} ${ALSO_WASM_CRATES}"
for crate in ${ALL_CRATES}; do
if grep "ink-fuzz-tests =" ./crates/${crate}/Cargo.toml;
then
cargo test --verbose --features ink-fuzz-tests --manifest-path ./crates/${crate}/Cargo.toml --no-fail-fast -- fuzz_ || exit_code=$?;
all_tests_passed=$(( all_tests_passed | exit_code ));
fi
done
exit ${all_tests_passed}
Loading

0 comments on commit 99370f1

Please sign in to comment.