FEAT: remember last selected backend across tabs #17
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: Playwright Tests | |
| on: | |
| push: | |
| branches: [ main, master ] | |
| pull_request: | |
| branches: [ main, master ] | |
| jobs: | |
| test: | |
| timeout-minutes: 60 | |
| runs-on: ubuntu-latest | |
| steps: | |
| - uses: actions/checkout@v4 | |
| - uses: actions/setup-node@v4 | |
| with: | |
| node-version: 22 | |
| - uses: astral-sh/setup-uv@v5 | |
| - name: Install Python dependencies | |
| working-directory: backend | |
| run: uv sync | |
| - name: Setup backend config | |
| working-directory: backend | |
| run: cp ../config.default.yaml config.yaml | |
| - name: Install node dependencies (webapp) | |
| working-directory: frontend | |
| run: npm ci | |
| - name: Install node dependencies (testing) | |
| working-directory: testing | |
| run: npm ci | |
| - name: Get Playwright version | |
| id: playwright-version | |
| working-directory: testing | |
| run: echo "version=$(npx playwright --version | awk '{print $2}')" >> $GITHUB_OUTPUT | |
| - name: Cache Playwright browsers | |
| id: playwright-cache | |
| uses: actions/cache@v4 | |
| with: | |
| path: ~/.cache/ms-playwright | |
| key: playwright-${{ runner.os }}-${{ steps.playwright-version.outputs.version }} | |
| - name: Install Playwright Browsers | |
| if: steps.playwright-cache.outputs.cache-hit != 'true' | |
| working-directory: testing | |
| run: npx playwright install --with-deps | |
| - name: Install Playwright system dependencies | |
| if: steps.playwright-cache.outputs.cache-hit == 'true' | |
| working-directory: testing | |
| run: npx playwright install-deps | |
| - name: Install Oxigraph (local SPARQL endpoint for e2e tests) | |
| run: | | |
| sudo curl -fsSL -o /usr/local/bin/oxigraph \ | |
| https://github.com/oxigraph/oxigraph/releases/download/v0.5.8/oxigraph_v0.5.8_x86_64_linux_gnu | |
| sudo chmod +x /usr/local/bin/oxigraph | |
| oxigraph --version | |
| - name: Run Playwright tests | |
| working-directory: testing | |
| run: npx playwright test | |
| - uses: actions/upload-artifact@v7 | |
| if: ${{ !cancelled() }} | |
| with: | |
| name: playwright-report | |
| path: testing/playwright-report/ | |
| retention-days: 30 |