Fix cypress test

This commit is contained in:
Ramon Wenger 2019-02-04 17:42:28 +01:00
parent 5a99c38afd
commit 6e60a17468
3 changed files with 20 additions and 66 deletions

View File

@ -36,7 +36,7 @@ aliases:
- echo "This pipeline rules!"
- *setup-tests
- npm install --prefix client
- npm run "install:cypress" --prefix client
# - npm run "install:cypress" --prefix client
- psql -U $DATABASE_USER -h $DATABASE_HOST -c "create database $DATABASE_NAME"
- python server/manage.py dummy_data
- python server/manage.py runserver &

File diff suppressed because one or more lines are too long

16
local-setup-for-tests.sh Executable file
View File

@ -0,0 +1,16 @@
#!/bin/bash
source ./setup-for-tests.sh
export DATABASE_HOST=postgres
export DATABASE_PORT=5432
export DATABASE_URL=postgres://$DATABASE_USER:$PG_PASSWORD@$DATABASE_HOST:$DATABASE_PORT/$DATABASE_NAME
psql -U $DATABASE_USER -h $DATABASE_HOST -c "drop database $DATABASE_NAME"
npm install --prefix client
#npm run "install:cypress" --prefix client
psql -U $DATABASE_USER -h $DATABASE_HOST -c "create database $DATABASE_NAME"
python server/manage.py dummy_data
python server/manage.py runserver &
npm run dev --prefix client &
cd client
/node_modules/.bin/cypress run