Skip to content

chore(deps): bump the js-dependencies group with 3 updates #74

chore(deps): bump the js-dependencies group with 3 updates

chore(deps): bump the js-dependencies group with 3 updates #74

Workflow file for this run

name: CI
on:
pull_request:
branches:
- main
- 1.12-compat
push:
branches:
- main
- 1.12-compat
workflow_dispatch:
jobs:
test:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v7
with:
fetch-depth: 0
- name: Install Bun
uses: oven-sh/setup-bun@v2
with:
bun-version: 1.3.14
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
- name: Install Rust
uses: actions-rust-lang/setup-rust-toolchain@v1
with:
toolchain: "1.92.0"
target: wasm32-unknown-unknown
components: rust-src
- name: Install wasm-pack
run: cargo install wasm-pack --version 0.15.0 --locked
- name: Install dependencies
run: bun install --frozen-lockfile
- name: Rust tests
run: bun run wasm:test || exit 1
- name: TypeScript tests
run: bun run test || exit 1
- name: Check wasm/pkg regenerated when Rust changed
if: github.event_name == 'pull_request'
run: |
base="${{ github.event.pull_request.base.sha }}"
src_changed=$(git diff --name-only "$base"...HEAD -- wasm/src wasm/Cargo.toml wasm/Cargo.lock)
pkg_changed=$(git diff --name-only "$base"...HEAD -- wasm/pkg)
if [ -n "$src_changed" ] && [ -z "$pkg_changed" ]; then
echo "::error::wasm/src or Cargo.* changed but wasm/pkg was not regenerated. Run 'bun run wasm:build' and commit wasm/pkg/."
echo "Changed Rust sources:"; echo "$src_changed"
exit 1
fi
echo "wasm/pkg check OK"
- name: Build
run: bun run build || exit 1