Add frontend test step to pipelines

This commit is contained in:
Ramon Wenger 2021-03-16 15:17:44 +01:00
parent 4045923da0
commit 7032cf4e39
1 changed files with 18 additions and 1 deletions

View File

@ -40,7 +40,7 @@ aliases:
- &setup-tests source setup-for-tests.sh
- ./server/run_unittests_coverage.sh
- &cypress-test
name: run cypress tests
name: run cypress end-to-end tests
caches:
- pip
- node
@ -62,6 +62,21 @@ aliases:
- npm run build --prefix client
- curl http://localhost:8000/beta-login
- npm run --prefix client test:cypress:e2e
- &frontend-test
name: run cypress frontend tests
caches:
- node
- clientmodules
- npm
artifacts:
- client/cypress/**/*.png
- client/cypress/**/*.mp4
script:
- npm ci --prefix client
- npm run "install:cypress" --prefix client
- npm run dev --prefix client &
- curl http://localhost:8080/beta-login
- npm run --prefix client test:cypress:frontend
- &jest-test
name: run jest tests
caches:
@ -108,6 +123,7 @@ pipelines:
- step: *lint
- step: *unittest-python
- step: *cypress-test
- step: *frontend-test
- step: *jest-test
- step: *deploy-dev
@ -123,6 +139,7 @@ pipelines:
- step: *lint
- step: *unittest-python
- step: *cypress-test
- step: *frontend-test
- step: *jest-test
- parallel:
- step: *deploy-stage