Skip to content

Commit

Permalink
💚 test fuzzing pipeline
Browse files Browse the repository at this point in the history
  • Loading branch information
lukacan committed May 23, 2024
1 parent 5cd0f0f commit 9147b3e
Show file tree
Hide file tree
Showing 2 changed files with 47 additions and 0 deletions.
23 changes: 23 additions & 0 deletions .github/actions/setup-honggfuzz/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
name: "Setup Honggfuzz"
description: "Setup Honggfuzz"

runs:
using: "composite"
steps:
- uses: actions/cache@v3
name: Cache Honggfuzz
id: cache-honggfuzz
with:
path: |
~/.cache/honggfuzz/
~/.local/share/honggfuzz/
key: honggfuzz-${{ runner.os }}-v0000
- name: Install honggfuzz
run: cargo install honggfuzz
shell: bash
- name: Install binutils-dev
run: sudo apt-get install binutils-dev
shell: bash
- name: Install libunwind-dev
run: sudo apt-get install libunwind-dev
shell: bash
24 changes: 24 additions & 0 deletions .github/workflows/run_fuzz_example.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Test Fuzz Tests

on:
workflow_dispatch:
pull_request:

env:
SOLANA_CLI_VERSION: 1.18.12
ANCHOR_VERSION: 0.29.0

jobs:
test_fuzz_example0:
runs-on: ubuntu-20.04
steps:
- uses: actions/checkout@v3
- uses: ./.github/actions/setup-rust/
- uses: ./.github/actions/setup-solana/
- uses: ./.github/actions/setup-honggfuzz/
id: rust-setup
- uses: Swatinem/rust-cache@v2
name: Cache Rust and it's packages
- name: Test Fuzz
working-directory: examples/fuzz-tests/unchecked-arithmetic-0
run: HFUZZ_RUN_ARGS="-N 10" cargo run --manifest-path ../../../Cargo.toml fuzz run fuzz_0

0 comments on commit 9147b3e

Please sign in to comment.