-
Notifications
You must be signed in to change notification settings - Fork 12
/
cider-ci.yml
171 lines (156 loc) · 5.45 KB
/
cider-ci.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
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
jobs:
basic-rspec-tests:
name: 'Basic Tests: Model, Controllers, ... '
run_when: &DEFAULT_TRIGGERS
the branch does not match no-ci or _wip_:
type: branch
include_match: &default_branch_match ^.+$
exclude_match: &default_branch_exclude ^(.*no-ci.*)|((greenkeeper|dependabot)\/.*)|([a-z]*(_|\/)wip_.*)$
context:
include: cider-ci/context-components/rspec-tests.yml
check-feature-tasks:
name: Check if feature tasks are up to date
run_when: *DEFAULT_TRIGGERS
context:
include: cider-ci/context-components/check-feature-tasks.yml
general-feature-tests:
name: 'General Feature Tests'
depends_on: &PLAIN_DEP
basic-rspec-tests:
job_key: basic-rspec-tests
type: job
states: [passed]
check-feature_tasks:
job_key: check-feature-tasks
type: job
states: [passed]
run_when: *PLAIN_DEP
context:
include: cider-ci/context-components/general-feature-tests.yml
embed-feature-tests:
name: 'Embed Feature Tests'
priority: 2
depends_on: *PLAIN_DEP
run_when: *PLAIN_DEP
context:
include: cider-ci/context-components/embed-feature-tests.yml
error-support-feature-tests:
name: 'Error-Support Feature Tests'
priority: 2
depends_on: *PLAIN_DEP
run_when: *PLAIN_DEP
context:
include: cider-ci/context-components/error-support-feature-tests.yml
custom-path-feature-tests:
name: 'Custom-Path Feature Tests'
priority: 2
depends_on: *PLAIN_DEP
run_when: *PLAIN_DEP
context:
include: cider-ci/context-components/custom-path-feature-tests.yml
lint:
name: 'Linting'
description: |
Code checks: static checks and metrics: complexity, duplication, and format,
also other consistency checks.
priority: 3
run_when: *DEFAULT_TRIGGERS
context:
include: [cider-ci/context-components/env.yml]
task_defaults:
environment_variables:
GIT_LINEAR_HISTORY_CHECK_START_SHA: 3eef3fe03c77970a301e641812e11a0d80a8d188
contexts:
include:
- path: cider-ci/context-components/lint/git-lint.yml
submodule: [datalayer]
- path: cider-ci/context-components/lint/rspec-lint.yml
submodule: [datalayer]
- path: cider-ci/context-components/lint/javascript-lint.yml
precompilation:
name: 'Precompilation'
run_when: *DEFAULT_TRIGGERS
priority: 99 # superproject build depends on some assets, so make them fast
context:
include: cider-ci/context-components/precompilation.yml
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
# META JOBS (only depend on other jobs) #
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
all-tests:
name: 'All tests'
description: |
This job depends on all unit jobs that need to pass.
It is depended upon by the super-project!
*Note that there still be more requirements for actually pushing to `origin`,
look in job **"Good to Merge"**!*
priority: 999 # "empty" job = high priority
context:
task: "echo '✔︎ All dependencies have passed' ; exit 0"
depends_on: &ALL_DEPS
'basic-tests passed':
type: job
job_key: basic-rspec-tests
states: [passed]
'general-feature-tests passed':
type: job
job_key: general-feature-tests
states: [passed]
'custom-path-feature-tests passed':
type: job
job_key: custom-path-feature-tests
states: [passed]
'embed-feature-tests passed':
type: job
job_key: embed-feature-tests
states: [passed]
'error-support-feature-tests passed':
type: job
job_key: error-support-feature-tests
states: [passed]
'lint passed':
type: job
job_key: lint
states: [passed]
'precompilation':
type: job
job_key: precompilation
states: [passed]
all-tests of the datalayer:
{ job_key: all-tests, type: job, submodule: [datalayer], states: [passed] }
run_when: *ALL_DEPS
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
# GITHUB BRANCH PROTECTION #
# # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # # #
good-to-merge:
name: '⚑ Good To Merge'
description: |
This job depends on all jobs that need to pass for "Delivery".
It is depended upon by GitHub's branch protection (for `master`)!
priority: 999 # "delivery" job = high priority
context:
include:
- path: cider-ci/context-components/env.yml
- submodule: [datalayer]
path: cider-ci/context-components/merge-checks.yml
depends_on: &GOOD_TO_MERGE_DEPS
all-tests: { job_key: all-tests, type: job, states: [passed] }
good to merge of the datalayer:
{ job_key: merged-to-master, type: job, submodule: [datalayer], states: [passed] }
run_when: *GOOD_TO_MERGE_DEPS
merged-to-master:
name: "Merged to master"
priority: 999
depends_on:
master branch matches:
type: branch
include_match: ^master$
run_when:
master branch matches:
type: branch
include_match: ^master$
context:
tasks:
merged-to-master:
scripts:
test:
body: "exit 0"