Skip to content

Commit

Permalink
Make CI fuzzing a container task
Browse files Browse the repository at this point in the history
  • Loading branch information
tgross35 committed Feb 19, 2024
1 parent d87eed2 commit 8627eb8
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 15 deletions.
21 changes: 7 additions & 14 deletions .github/workflows/fuzz.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,23 +22,16 @@ jobs:
name: Parser fuzzing
runs-on: ubuntu-latest
timeout-minutes: 25
# Run in a container because we had some issues reproducing failures
container:
image: debian:bookworm
steps:
- uses: actions/checkout@v4
- uses: taiki-e/install-action@just
- name: Get npm cache directory
id: npm-cache-dir
shell: bash
run: echo "dir=$(npm config get cache)" >> ${GITHUB_OUTPUT}
- uses: actions/cache@v4
id: npm-cache
with:
path: ${{ steps.npm-cache-dir.outputs.dir }}
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }}
restore-keys: ${{ runner.os }}-node-
- run: |
npm --version
npx --version
clang --version
apt update
apt install -y clang curl
curl --proto '=https' --tlsv1.2 -sSf https://just.systems/install.sh |
bash -s -- --to /usr/bin
- run: just setup
- run: just fuzz
- name: Print failures
Expand Down
6 changes: 5 additions & 1 deletion justfile
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,11 @@ setup:
check_installed clang-tidy
check_installed clang-format

npm install --include=dev
if which npm > /dev/null; then
npm install --include=dev
else
echo "npm not found: skipping install"
fi

# Lint with more minimal dependencies that can be run during pre-commit
_lint-min: tree-sitter-clone configure-compile-database
Expand Down

0 comments on commit 8627eb8

Please sign in to comment.