forked from aldefouw/redcap_cypress
-
Notifications
You must be signed in to change notification settings - Fork 0
/
circle.yml
46 lines (45 loc) · 1.35 KB
/
circle.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
version: 2.0
jobs:
build:
machine:
image: ubuntu-1604:201903-01
steps:
- checkout
- run:
name: Install MySQL Client
command: |
sudo apt-get update
sudo apt-get install mysql-client-core-5.7
- run:
name: Build the REDCap Image
command: |
git clone --branch redcap-cypress https://github.com/aldefouw/redcap_docker
- run:
name: Get REDCap Source
command: |
git clone --branch redcap-cypress https://github.com/aldefouw/redcap_source www
- run:
name: Start Docker REDCap Container
command: |
cd redcap_docker
docker-compose up -d --build
- run:
name: Configure Cypress environment
command: |
cd /home/circleci/project
sed s/PID/$PROJECT_ID/g cypress.json.example > cypress.json
mv cypress.env.json.example cypress.env.json
- run:
name: Install Cypress and Run Tests
command: |
export NVM_DIR="/opt/circleci/.nvm"
[ -s "$NVM_DIR/nvm.sh" ] && \. "$NVM_DIR/nvm.sh"
nvm use stable
npm install
npx cypress run --record --key $RECORD_KEY
workflows:
version: 2
workflow:
jobs:
- build:
context: REDCap Tests