ci: parallelize config
This commit is contained in:
parent
94d692b0cf
commit
ca2759fc7d
@ -3,62 +3,60 @@ version: 2
|
|||||||
defaults: &defaults
|
defaults: &defaults
|
||||||
docker:
|
docker:
|
||||||
- image: vuejs/ci
|
- image: vuejs/ci
|
||||||
working_directory: ~/project/vue
|
|
||||||
|
step_restore_cache: &restore_cache
|
||||||
|
restore_cache:
|
||||||
|
keys:
|
||||||
|
- v1-dependencies-{{ checksum "yarn.lock" }}
|
||||||
|
- v1-dependencies-
|
||||||
|
|
||||||
|
step_install_deps: &install_deps
|
||||||
|
run:
|
||||||
|
name: Install Dependencies
|
||||||
|
command: yarn --frozen-lockfile
|
||||||
|
|
||||||
|
step_save_cache: &save_cache
|
||||||
|
save_cache:
|
||||||
|
paths:
|
||||||
|
- node_modules
|
||||||
|
- packages/compiler-core/node_modules
|
||||||
|
- packages/compiler-sfc/node_modules
|
||||||
|
- packages/vue/node_modules
|
||||||
|
- ~/.cache/yarn
|
||||||
|
key: v1-dependencies-{{ checksum "yarn.lock" }}
|
||||||
|
|
||||||
jobs:
|
jobs:
|
||||||
install:
|
|
||||||
<<: *defaults
|
|
||||||
steps:
|
|
||||||
- checkout
|
|
||||||
- restore_cache:
|
|
||||||
keys:
|
|
||||||
- v1-dependencies-{{ checksum "yarn.lock" }}
|
|
||||||
- v1-dependencies-
|
|
||||||
- run:
|
|
||||||
name: Install Dependencies
|
|
||||||
command: yarn --frozen-lockfile
|
|
||||||
- save_cache:
|
|
||||||
paths:
|
|
||||||
- node_modules
|
|
||||||
- ~/.cache/yarn
|
|
||||||
key: v1-dependencies-{{ checksum "yarn.lock" }}
|
|
||||||
- persist_to_workspace:
|
|
||||||
root: ~/project
|
|
||||||
paths:
|
|
||||||
- vue
|
|
||||||
|
|
||||||
test:
|
test:
|
||||||
<<: *defaults
|
<<: *defaults
|
||||||
steps:
|
steps:
|
||||||
- attach_workspace:
|
- checkout
|
||||||
at: ~/project
|
- *restore_cache
|
||||||
|
- *install_deps
|
||||||
|
- *save_cache
|
||||||
- run: yarn test --ci --runInBand
|
- run: yarn test --ci --runInBand
|
||||||
|
|
||||||
test-dts:
|
test-dts:
|
||||||
<<: *defaults
|
<<: *defaults
|
||||||
steps:
|
steps:
|
||||||
- attach_workspace:
|
- checkout
|
||||||
at: ~/project
|
- *restore_cache
|
||||||
|
- *install_deps
|
||||||
|
- *save_cache
|
||||||
- run: yarn test-dts
|
- run: yarn test-dts
|
||||||
|
|
||||||
check-size:
|
check-size:
|
||||||
<<: *defaults
|
<<: *defaults
|
||||||
steps:
|
steps:
|
||||||
- attach_workspace:
|
- checkout
|
||||||
at: ~/project
|
- *restore_cache
|
||||||
|
- *install_deps
|
||||||
|
- *save_cache
|
||||||
- run: yarn size
|
- run: yarn size
|
||||||
|
|
||||||
workflows:
|
workflows:
|
||||||
version: 2
|
version: 2
|
||||||
ci:
|
ci:
|
||||||
jobs:
|
jobs:
|
||||||
- install
|
- test
|
||||||
- test:
|
- test-dts
|
||||||
requires:
|
- check-size
|
||||||
- install
|
|
||||||
- test-dts:
|
|
||||||
requires:
|
|
||||||
- install
|
|
||||||
- check-size:
|
|
||||||
requires:
|
|
||||||
- install
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user