Merge branch 'main' into stable #104
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: frontend-test | |
on: | |
workflow_dispatch: | |
push: | |
paths: | |
- 'frontend/**' | |
- '!frontend/con10t/**' | |
branches: | |
- main | |
- stable | |
defaults: | |
run: | |
working-directory: frontend | |
env: | |
TEST_SERVER: bogusman02.dai-cloud.uni-koeln.de | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Cache npm modules | |
uses: actions/cache@v2 | |
with: | |
path: ~/.npm | |
key: ${{ runner.os }}-node-${{ hashFiles('**/package-lock.json') }} | |
restore-keys: | | |
${{ runner.os }}-node- | |
- name: Install npm dependencies | |
run: npm i | |
- name: Run unit tests | |
run: npm run test | |
# - name: Set backend URI to test server | |
# run: sed -i 's/document.location.host/\"'"${{ env.TEST_SERVER }}"'\"/' app/app.js | |
# - name: Start dev server (in background) | |
# run: npm start & | |
# - name: Run e2e tests | |
# run: xvfb-run -n 97 npm run e2e | |
# - name: Reset backend URI | |
# run: sed -i 's/\"'"${{ env.TEST_SERVER }}"'\"/document.location.host/' app/app.js |