1
1
version : 2
2
2
3
3
jobs :
4
- " test " :
4
+ " test-v0 " :
5
5
docker :
6
6
- image : circleci/python:3.6-node-browsers
7
7
- image : cypress/base:10
@@ -33,12 +33,60 @@ jobs:
33
33
name : Install requirements
34
34
command : |
35
35
. venv/bin/activate
36
- pip install -r requirements.txt --quiet
36
+ pip install -r requirements-base.txt --quiet
37
+ pip install -r requirements-v0.txt --quiet
38
+
39
+ - run :
40
+ name : Run build:js
41
+ command : npm run private::build:js-test
42
+
43
+ - run :
44
+ name : Run build:py
45
+ command : |
46
+ . venv/bin/activate
47
+ npm run private::build:py
48
+
49
+ - run :
50
+ name : Run tests
51
+ command : |
52
+ . venv/bin/activate
53
+ npm run test-v0
54
+
55
+
56
+ " test-v1 " :
57
+ docker :
58
+ - image : circleci/python:3.6-node-browsers
59
+ - image : cypress/base:10
60
+
61
+ steps :
62
+ - checkout
63
+ - restore_cache :
64
+ key : deps1-{{ .Branch }}-{{ checksum "package-lock.json" }}-{{ checksum "package.json" }}-{{ checksum ".circleci/config.yml" }}
65
+ - run :
66
+ name : Install npm packages
67
+ command : npm install
68
+ - run :
69
+ name : Cypress Install
70
+ command : |
71
+ $(npm bin)/cypress install
37
72
38
73
- save_cache :
39
- key : deps1-{{ .Branch }}-{{ checksum "requirements.txt " }}
74
+ key : deps1-{{ .Branch }}-{{ checksum "package-lock.json" }}-{{ checksum "package.json" }}-{{ checksum ".circleci/config.yml " }}
40
75
paths :
41
- - " venv"
76
+ - node_modules
77
+ - /home/circleci/.cache/Cypress
78
+
79
+ - run :
80
+ name : Create virtualenv
81
+ command : |
82
+ python3 -m venv venv
83
+
84
+ - run :
85
+ name : Install requirements
86
+ command : |
87
+ . venv/bin/activate
88
+ pip install -r requirements-base.txt --quiet
89
+ pip install -r requirements-v1.txt --quiet
42
90
43
91
- run :
44
92
name : Run build:js
54
102
name : Run tests
55
103
command : |
56
104
. venv/bin/activate
57
- npm run test
105
+ npm run test-v1
58
106
59
107
60
108
" visual-test " :
@@ -110,24 +158,21 @@ jobs:
110
158
when : always
111
159
112
160
113
- " python-3.6 " :
161
+ " python-3.6-v0 " :
114
162
docker :
115
163
- image : circleci/python:3.6-stretch-browsers
116
164
117
165
environment :
118
166
PERCY_ENABLED : True
119
- PERCY_PROJECT : plotly/dash-table-python
167
+ PERCY_PROJECT : plotly/dash-table-python-v0
120
168
121
169
steps :
122
170
- checkout
123
171
124
172
- run :
125
173
name : Inject Percy Environment variables
126
174
command : |
127
- echo 'export PERCY_TOKEN="$PERCY_PYTHON_TOKEN"' >> $BASH_ENV
128
-
129
- - restore_cache :
130
- key : deps1-{{ .Branch }}-{{ checksum "requirements.txt" }}
175
+ echo 'export PERCY_TOKEN="$PERCY_PYTHON_TOKEN_V0"' >> $BASH_ENV
131
176
132
177
- run :
133
178
name : Create virtualenv
@@ -138,12 +183,8 @@ jobs:
138
183
name : Install requirements
139
184
command : |
140
185
. venv/bin/activate
141
- pip install -r requirements.txt --quiet
142
-
143
- - save_cache :
144
- key : deps1-{{ .Branch }}-{{ checksum "requirements.txt" }}
145
- paths :
146
- - " venv"
186
+ pip install -r requirements-base.txt --quiet
187
+ pip install -r requirements-v0.txt --quiet
147
188
148
189
- run :
149
190
name : Run integration tests
@@ -152,12 +193,48 @@ jobs:
152
193
python -m unittest tests.dash.test_integration
153
194
154
195
196
+ " python-3.6-v1 " :
197
+ docker :
198
+ - image : circleci/python:3.6-stretch-browsers
199
+
200
+ environment :
201
+ PERCY_ENABLED : True
202
+ PERCY_PROJECT : plotly/dash-table-python-v1
203
+
204
+ steps :
205
+ - checkout
206
+
207
+ - run :
208
+ name : Inject Percy Environment variables
209
+ command : |
210
+ echo 'export PERCY_TOKEN="$PERCY_PYTHON_TOKEN_V1"' >> $BASH_ENV
211
+
212
+ - run :
213
+ name : Create virtualenv
214
+ command : |
215
+ python3 -m venv venv
216
+
217
+ - run :
218
+ name : Install requirements
219
+ command : |
220
+ . venv/bin/activate
221
+ pip install -r requirements-base.txt --quiet
222
+ pip install -r requirements-v1.txt --quiet
223
+
224
+ - run :
225
+ name : Run integration tests
226
+ command : |
227
+ . venv/bin/activate
228
+ python -m unittest tests.dash.test_integration
229
+
155
230
156
231
workflows :
157
232
version : 2
158
233
build :
159
234
jobs :
160
- - " python-3.6"
235
+ - " python-3.6-v0"
236
+ - " python-3.6-v1"
161
237
- " node"
162
- - " test"
238
+ - " test-v0"
239
+ - " test-v1"
163
240
- " visual-test"
0 commit comments