clearAll button #172
This file contains 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: Node Js | |
on: [push] | |
jobs: | |
# Job for building the frontend | |
build-frontend: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} # Remove if not using matrix strategy | |
cache: 'npm' | |
- run: npm install | |
- run: npm ci | |
- run: npm start | |
- run: dir "frontend\public\index.html" | |
- run: npm run build | |
# Job for running the backend server | |
run-backend: | |
runs-on: windows-latest # Consider using different runners for different needs | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} # Remove if not using matrix strategy | |
cache: 'npm' | |
- run: npm install | |
- run: npm ci | |
- run: node "backend\server.js" | |
timeout-minutes: 10 | |
run-tests: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} # Remove if not using matrix strategy | |
cache: 'npm' | |
- run: npm install | |
- run: npm test "frontend\src\AppTest.js" |