Skip to content

Merge pull request #11 from bytecodealliance/bump-cjs #34

Merge pull request #11 from bytecodealliance/bump-cjs

Merge pull request #11 from bytecodealliance/bump-cjs #34

Workflow file for this run

name: CI
on:
push:
branches: [main]
pull_request:
branches: [main]
jobs:
setup-and-test:
runs-on: ubuntu-latest
strategy:
matrix:
server: [itty-router, hono]
include:
- server: itty-router
build_cmd: npm run build
- server: hono
build_cmd: npm run build:hono
name: test (${{ matrix.server }})
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "23"
cache: "npm"
- name: Install Wasmtime
run: |
curl https://wasmtime.dev/install.sh -sSf | bash
echo "$HOME/.wasmtime/bin" >> $GITHUB_PATH
- name: Build the project
run: npm ci && ${{ matrix.build_cmd }}
- name: Run tests
run: npm test
lint:
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Node.js
uses: actions/setup-node@v4
with:
node-version: "23"
cache: "npm"
- name: Install dependencies
run: npm ci
- name: Run format checks
run: npm run fmt:check
- name: Run linter
run: npm run lint