Skip to content

chore: release v0.3.2 #47

chore: release v0.3.2

chore: release v0.3.2 #47

Workflow file for this run

name: Test
on:
push:
branches: [ master ]
pull_request:
branches: [ master ]
jobs:
test:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [22.x, 24.x]
steps:
- uses: actions/checkout@v4
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v4
with:
node-version: ${{ matrix.node-version }}
cache: 'npm'
- name: Check Node.js version
run: |
echo "Node.js version: $(node --version)"
echo "npm version: $(npm --version)"
echo "Node.js major version: $(node --version | cut -d. -f1 | tr -d v)"
- name: Install dependencies
run: npm ci
- name: Clean and build project
run: |
# Clean any existing build artifacts
rm -rf dist/
# Build the project
npm run build
# Verify build artifacts exist
ls -la dist/
- name: Run tests
run: |
# Run tests with retry mechanism for better stability
for i in {1..3}; do
echo "Test attempt $i/3"
if npm test; then
echo "Tests passed on attempt $i"
break
elif [ $i -eq 3 ]; then
echo "Tests failed after 3 attempts"
exit 1
else
echo "Test attempt $i failed, retrying..."
sleep 5
fi
done
env:
# Set longer timeout for tests
VITEST_TIMEOUT: 60000
# Uncomment the next line to skip hook tests
SKIP_HOOK_TESTS: true
- name: Run linting
run: npm run lint
- name: Check formatting
run: npx prettier --check src/ test/
- name: Test development mode compatibility
run: npm run dev -- --version