Merge branch 'testing' into fix/levelsystem #163
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: | |
build-frontend: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Setup Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
cache: 'npm' | |
- name: Run npm build | |
working-directory: frontend/public | |
run: | | |
npm install react-scripts | |
npm run build | |
run-backend: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Setup Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
cache: 'npm' | |
- name: Start the backend server | |
working-directory: backend | |
run: | | |
npm ci | |
node "server.js" | |
timeout-minutes: 4 | |
run-tests: | |
runs-on: windows-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Setup Node.js | |
uses: actions/setup-node@v3 | |
with: | |
node-version: ${{ matrix.node-version }} | |
cache: 'npm' | |
- name: Run tests | |
working-directory: "frontend/src/" | |
run: | |
npm install react-scripts | |
npm test "AppTest.js" |