feat: Add Vitest testing framework for frontend #1
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: Frontend Tests | |
| # This workflow runs ONLY on pull requests to the main and develop branches | |
| on: | |
| pull_request: | |
| branches: [ "main", "develop" ] | |
| jobs: | |
| frontend-tests: | |
| name: Frontend Tests | |
| runs-on: ubuntu-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Setup Node.js | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20.x' | |
| - name: Install frontend dependencies | |
| run: npm ci | |
| working-directory: ./frontend | |
| - name: Run frontend tests | |
| run: npm test | |
| working-directory: ./frontend |