2017-09-18 22:09:22 +08:00
|
|
|
version: 2
|
|
|
|
|
|
|
|
defaults: &defaults
|
|
|
|
working_directory: ~/project/vue
|
|
|
|
docker:
|
2018-10-23 04:21:01 +08:00
|
|
|
- image: vuejs/ci
|
2017-09-18 22:09:22 +08:00
|
|
|
|
|
|
|
jobs:
|
|
|
|
install:
|
|
|
|
<<: *defaults
|
|
|
|
steps:
|
|
|
|
- checkout
|
|
|
|
- restore_cache:
|
|
|
|
keys:
|
2018-03-12 21:34:02 +08:00
|
|
|
- v1-vue-{{ .Branch }}-{{ checksum "yarn.lock" }}
|
2017-09-18 22:09:22 +08:00
|
|
|
- v1-vue-{{ .Branch }}-
|
|
|
|
- v1-vue-
|
2017-10-07 05:41:54 +08:00
|
|
|
- run: npm install
|
2017-09-18 22:09:22 +08:00
|
|
|
- save_cache:
|
2018-03-12 21:34:02 +08:00
|
|
|
key: v1-vue-{{ .Branch }}-{{ checksum "yarn.lock" }}
|
2017-09-18 22:09:22 +08:00
|
|
|
paths:
|
|
|
|
- node_modules/
|
|
|
|
- persist_to_workspace:
|
|
|
|
root: ~/project
|
|
|
|
paths:
|
|
|
|
- vue
|
|
|
|
|
2021-04-07 00:05:05 +08:00
|
|
|
lint-ts-types:
|
2017-09-18 22:09:22 +08:00
|
|
|
<<: *defaults
|
|
|
|
steps:
|
|
|
|
- attach_workspace:
|
|
|
|
at: ~/project
|
|
|
|
- run: npm run lint
|
2021-04-07 00:05:05 +08:00
|
|
|
- run: npm run ts-check
|
2017-09-18 22:09:22 +08:00
|
|
|
- run: npm run test:types
|
|
|
|
|
|
|
|
test-cover:
|
|
|
|
<<: *defaults
|
|
|
|
steps:
|
|
|
|
- attach_workspace:
|
|
|
|
at: ~/project
|
|
|
|
- run: npm run test:cover
|
|
|
|
- run:
|
|
|
|
name: report coverage stats for non-PRs
|
|
|
|
command: |
|
|
|
|
if [[ -z $CI_PULL_REQUEST ]]; then
|
2018-03-09 00:55:01 +08:00
|
|
|
./node_modules/.bin/codecov
|
2017-09-18 22:09:22 +08:00
|
|
|
fi
|
|
|
|
|
|
|
|
test-e2e:
|
|
|
|
<<: *defaults
|
|
|
|
steps:
|
|
|
|
- attach_workspace:
|
|
|
|
at: ~/project
|
|
|
|
- run: npm run test:e2e -- --env phantomjs
|
|
|
|
|
|
|
|
test-ssr-weex:
|
|
|
|
<<: *defaults
|
|
|
|
steps:
|
|
|
|
- attach_workspace:
|
|
|
|
at: ~/project
|
|
|
|
- run: npm run test:ssr
|
|
|
|
- run: npm run test:weex
|
|
|
|
|
2018-12-03 05:00:06 +08:00
|
|
|
trigger-regression-test:
|
|
|
|
<<: *defaults
|
|
|
|
steps:
|
|
|
|
- run:
|
|
|
|
command: |
|
|
|
|
curl --user ${CIRCLE_TOKEN}: \
|
|
|
|
--data build_parameters[CIRCLE_JOB]=update \
|
|
|
|
--data build_parameters[VUE_REVISION]=${CIRCLE_SHA1} \
|
|
|
|
https://circleci.com/api/v1.1/project/github/vuejs/regression-testing/tree/master
|
|
|
|
|
2017-09-18 22:09:22 +08:00
|
|
|
workflows:
|
|
|
|
version: 2
|
|
|
|
install-and-parallel-test:
|
|
|
|
jobs:
|
|
|
|
- install
|
|
|
|
- test-cover:
|
|
|
|
requires:
|
|
|
|
- install
|
2021-04-07 00:05:05 +08:00
|
|
|
- lint-ts-types:
|
2017-09-18 22:09:22 +08:00
|
|
|
requires:
|
|
|
|
- install
|
|
|
|
- test-e2e:
|
|
|
|
requires:
|
|
|
|
- install
|
|
|
|
- test-ssr-weex:
|
|
|
|
requires:
|
|
|
|
- install
|
2018-12-03 05:00:06 +08:00
|
|
|
- trigger-regression-test:
|
|
|
|
filters:
|
|
|
|
branches:
|
|
|
|
only:
|
2019-01-11 01:44:31 +08:00
|
|
|
- "2.6"
|
2018-12-03 05:00:06 +08:00
|
|
|
- regression-test
|
|
|
|
requires:
|
|
|
|
- test-cover
|
2021-04-07 00:05:05 +08:00
|
|
|
- lint-ts-types
|
2018-12-03 05:00:06 +08:00
|
|
|
- test-e2e
|
|
|
|
- test-ssr-weex
|
|
|
|
weekly_regression_test:
|
|
|
|
triggers:
|
|
|
|
- schedule:
|
|
|
|
# At 13:00 UTC (9:00 EDT) on every Monday
|
|
|
|
cron: "0 13 * * 1"
|
|
|
|
filters:
|
|
|
|
branches:
|
|
|
|
only:
|
|
|
|
dev
|
|
|
|
jobs:
|
|
|
|
- install
|
|
|
|
- test-cover:
|
|
|
|
requires:
|
|
|
|
- install
|
2021-04-07 00:05:05 +08:00
|
|
|
- lint-ts-types:
|
2018-12-03 05:00:06 +08:00
|
|
|
requires:
|
|
|
|
- install
|
|
|
|
- test-e2e:
|
|
|
|
requires:
|
|
|
|
- install
|
|
|
|
- test-ssr-weex:
|
|
|
|
requires:
|
|
|
|
- install
|
|
|
|
- trigger-regression-test:
|
|
|
|
requires:
|
|
|
|
- test-cover
|
2021-04-07 00:05:05 +08:00
|
|
|
- lint-ts-types
|
2018-12-03 05:00:06 +08:00
|
|
|
- test-e2e
|
|
|
|
- test-ssr-weex
|