chore: update playground version displays to 0.15.1 #55
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Playground E2E Tests | |
| on: | |
| workflow_dispatch: | |
| push: | |
| paths: | |
| - 'playground/**' | |
| - 'crates/utf8proj-wasm/**' | |
| - 'crates/utf8proj-core/**' | |
| - 'crates/utf8proj-parser/**' | |
| - 'crates/utf8proj-solver/**' | |
| - 'crates/utf8proj-render/**' | |
| - '.github/workflows/playground-tests.yml' | |
| pull_request: | |
| paths: | |
| - 'playground/**' | |
| - 'crates/utf8proj-wasm/**' | |
| - 'crates/utf8proj-core/**' | |
| - 'crates/utf8proj-parser/**' | |
| - 'crates/utf8proj-solver/**' | |
| - 'crates/utf8proj-render/**' | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 15 | |
| steps: | |
| - name: Checkout | |
| uses: actions/checkout@v4 | |
| - name: Setup Rust | |
| uses: dtolnay/rust-toolchain@stable | |
| with: | |
| targets: wasm32-unknown-unknown | |
| - name: Cache Rust dependencies | |
| uses: Swatinem/rust-cache@v2 | |
| with: | |
| workspaces: "crates/utf8proj-wasm" | |
| - name: Install wasm-pack | |
| run: curl https://rustwasm.github.io/wasm-pack/installer/init.sh -sSf | sh | |
| - name: Build WASM | |
| run: | | |
| cd crates/utf8proj-wasm | |
| wasm-pack build --target web --out-dir ../../playground/pkg | |
| rm -f ../../playground/pkg/.gitignore | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| cache: 'npm' | |
| cache-dependency-path: playground/package.json | |
| - name: Install dependencies | |
| run: cd playground && npm ci || npm install | |
| - name: Install Playwright browsers | |
| run: cd playground && npx playwright install chromium --with-deps | |
| - name: Run E2E tests | |
| run: cd playground && npm test | |
| - name: Upload test results | |
| if: failure() | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: playwright-report | |
| path: playground/test-results/ | |
| retention-days: 7 |