PR for testing the test workflow #7
Workflow file for this run
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: Test Workflow | |
| on: | |
| # push: | |
| # branches: [main] | |
| pull_request: | |
| branches: [test-workflow] # temporary for testing | |
| workflow_dispatch: | |
| jobs: | |
| test: | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout code | |
| uses: actions/checkout@v5 | |
| - name: Install pnpm | |
| uses: pnpm/action-setup@v5 | |
| with: | |
| version: 10 | |
| - name: Use Node.js | |
| uses: actions/setup-node@v5 | |
| with: | |
| node-version: 24.14.0 | |
| cache: 'pnpm' | |
| - name: Install Dependencies | |
| run: pnpm i | |
| - name: Generate SvelteKit config | |
| run: pnpm svelte-kit sync | |
| - name: Update and Test database | |
| env: | |
| DB_URL: file:database/local.db | |
| DB_VISITS_URL: file:database/visits.db | |
| run: pnpm db:update | |
| comment-on-failure: | |
| needs: test | |
| if: ${{ failure() && github.event_name == 'pull_request' }} | |
| runs-on: ubuntu-latest | |
| permissions: | |
| pull-requests: write | |
| steps: | |
| - uses: peter-evans/create-or-update-comment@v5 | |
| with: | |
| token: ${{ secrets.GITHUB_TOKEN }} | |
| issue-number: ${{ github.event.pull_request.number }} | |
| body: | | |
| The tests have failed. Please examine the logs to identify the root cause. Learn more about these tests in the [contribution guidelines](https://github.com/ScriptRaccoon/CatDat/blob/main/CONTRIBUTING.md). |