Skip to content

Commit d6804f3

Browse files
committed
Added comprehensive testing validation checklist for split CircleCI configurations.
1 parent a20605b commit d6804f3

File tree

1 file changed

+344
-0
lines changed

1 file changed

+344
-0
lines changed

.circleci/TESTING.md

Lines changed: 344 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,344 @@
1+
# Testing CircleCI Multiple Configuration Files
2+
3+
This document provides a comprehensive testing checklist for validating the split CircleCI configuration files.
4+
5+
## Pre-Testing Requirements
6+
7+
- [ ] CircleCI account connected to GitHub
8+
- [ ] CircleCI GitHub App integration installed
9+
- [ ] Test branch created (`feature/1571-split-circleci-config`)
10+
- [ ] All config files committed to repository
11+
- [ ] Access to CircleCI project settings
12+
13+
## Pipeline Configuration Testing
14+
15+
### 1. Configure Pipelines in CircleCI UI
16+
17+
For each pipeline, verify configuration:
18+
19+
#### build-test-deploy.yml
20+
- [ ] Pipeline created with name: `Database, Build, Test and Deploy`
21+
- [ ] Config path set to: `.circleci/build-test-deploy.yml`
22+
- [ ] Trigger configured for: Push to all branches
23+
- [ ] Trigger configured for: Push to all tags
24+
- [ ] Environment variables accessible
25+
26+
#### database-nightly.yml
27+
- [ ] Pipeline created with name: `Database - Nightly refresh`
28+
- [ ] Config path set to: `.circleci/database-nightly.yml`
29+
- [ ] Trigger configured for: Schedule `0 18 * * *`
30+
- [ ] Target branch set to: `develop`
31+
- [ ] SSH key for database downloads added
32+
33+
#### update-dependencies.yml
34+
- [ ] Pipeline created with name: `Update dependencies`
35+
- [ ] Config path set to: `.circleci/update-dependencies.yml`
36+
- [ ] Trigger configured for: Schedule `5 11,23 * * *`
37+
- [ ] Target branch set to: `develop`
38+
- [ ] Manual trigger parameter configured
39+
- [ ] RENOVATE_TOKEN environment variable set
40+
- [ ] RENOVATE_REPOSITORIES environment variable set
41+
- [ ] RENOVATE_GIT_AUTHOR environment variable set
42+
43+
#### vortex-test-postbuild.yml
44+
- [ ] Pipeline created with name: `Vortex - Test (Post-build)`
45+
- [ ] Config path set to: `.circleci/vortex-test-postbuild.yml`
46+
- [ ] Trigger configured for: Push to all branches
47+
- [ ] Trigger configured for: Push to all tags
48+
49+
#### vortex-test-didi-fi.yml
50+
- [ ] Pipeline created with name: `Vortex - Test (DIDI from file)`
51+
- [ ] Config path set to: `.circleci/vortex-test-didi-fi.yml`
52+
- [ ] Trigger configured for: Push to all branches
53+
- [ ] SSH key for database downloads added
54+
55+
#### vortex-test-didi-ii.yml
56+
- [ ] Pipeline created with name: `Vortex - Test (DIDI from registry)`
57+
- [ ] Config path set to: `.circleci/vortex-test-didi-ii.yml`
58+
- [ ] Trigger configured for: Push to all branches
59+
- [ ] SSH key for database downloads added
60+
61+
## Functional Testing
62+
63+
### 2. Test Main Pipeline (build-test-deploy.yml)
64+
65+
#### Push to Feature Branch
66+
- [ ] Push commit to test branch
67+
- [ ] Verify pipeline triggers automatically
68+
- [ ] **database job:**
69+
- [ ] Starts automatically
70+
- [ ] Downloads database successfully
71+
- [ ] Caches database correctly
72+
- [ ] Exports database after download
73+
- [ ] **build job:**
74+
- [ ] Waits for database job to complete
75+
- [ ] Validates Composer configuration
76+
- [ ] Restores database cache
77+
- [ ] Sets up remote Docker
78+
- [ ] Lints Dockerfiles with Hadolint
79+
- [ ] Lints Docker Compose with DCLint
80+
- [ ] Builds Docker stack
81+
- [ ] Installs dependencies
82+
- [ ] Validates Composer normalization
83+
- [ ] Runs all linters (PHPCS, PHPStan, Rector, PHPMD, Twig CS Fixer)
84+
- [ ] Provisions site successfully
85+
- [ ] Runs PHPUnit tests
86+
- [ ] Runs Behat tests
87+
- [ ] Stores test results
88+
- [ ] Stores artifacts
89+
- [ ] Uploads coverage to Codecov
90+
- [ ] **deploy job:**
91+
- [ ] Does NOT run (feature branch not in allowed list)
92+
93+
#### Push to develop Branch
94+
- [ ] Push commit to develop branch (or merge PR)
95+
- [ ] Verify pipeline triggers automatically
96+
- [ ] **database job:** Runs and completes
97+
- [ ] **build job:** Runs and completes
98+
- [ ] **deploy job:**
99+
- [ ] Starts after build completes
100+
- [ ] Checks deployment should not be skipped
101+
- [ ] Runs deployment script
102+
- [ ] Stores artifacts
103+
104+
#### Create and Push Tag
105+
- [ ] Create semver tag (e.g., `1.0.0`)
106+
- [ ] Push tag to repository
107+
- [ ] Verify pipeline triggers for tag
108+
- [ ] **database job:** Runs and completes
109+
- [ ] **build job:** Runs and completes
110+
- [ ] **deploy job:** Does NOT run (ignores branches)
111+
- [ ] **deploy-tags job:**
112+
- [ ] Starts after build completes
113+
- [ ] Runs tag deployment
114+
- [ ] Stores artifacts
115+
116+
### 3. Test Database Nightly Pipeline (database-nightly.yml)
117+
118+
#### Manual Trigger Test
119+
- [ ] Manually trigger pipeline (if supported)
120+
- [ ] OR wait for scheduled run at 18:00 UTC
121+
- [ ] **database-nightly job:**
122+
- [ ] Runs on develop branch only
123+
- [ ] Downloads fresh database (ignores fallback)
124+
- [ ] Uses fresh base image
125+
- [ ] Exports to container registry
126+
- [ ] Skips frontend build
127+
- [ ] Caches database correctly
128+
129+
### 4. Test Update Dependencies Pipeline (update-dependencies.yml)
130+
131+
#### Scheduled Trigger Test
132+
- [ ] Wait for scheduled run at 11:05 or 23:05 UTC
133+
- [ ] OR manually trigger via parameter
134+
- [ ] **update-dependencies job:**
135+
- [ ] Checks RENOVATE_TOKEN is set
136+
- [ ] Checks RENOVATE_REPOSITORIES is set
137+
- [ ] Checks RENOVATE_GIT_AUTHOR is set
138+
- [ ] Validates Renovate configuration
139+
- [ ] Runs Renovate successfully
140+
141+
#### Manual Trigger Test
142+
- [ ] Trigger pipeline with parameter `run_update_dependencies=true`
143+
- [ ] Verify pipeline runs immediately
144+
- [ ] Verify job completes successfully
145+
146+
### 5. Test Vortex Post-Build Pipeline (vortex-test-postbuild.yml)
147+
148+
#### Push to Any Branch
149+
- [ ] Push commit to test branch
150+
- [ ] Verify pipeline triggers
151+
- [ ] **vortex-test-postbuild job:**
152+
- [ ] Installs Ahoy
153+
- [ ] Installs test dependencies
154+
- [ ] Runs post-build tests
155+
- [ ] Stores test results
156+
- [ ] Stores artifacts
157+
158+
### 6. Test Vortex DIDI-FI Pipeline (vortex-test-didi-fi.yml)
159+
160+
#### Push to Any Branch
161+
- [ ] Push commit to test branch
162+
- [ ] Verify pipeline triggers
163+
- [ ] **vortex-test-didi-database-fi job:**
164+
- [ ] Downloads DB from URL
165+
- [ ] Creates DB image
166+
- [ ] Pushes image to registry
167+
- [ ] Uses custom cache key
168+
- [ ] **vortex-test-didi-build-fi job:**
169+
- [ ] Waits for database job
170+
- [ ] Restores cache with custom key
171+
- [ ] Builds site with DIDI image
172+
- [ ] Provisions successfully
173+
- [ ] Stores results
174+
175+
### 7. Test Vortex DIDI-II Pipeline (vortex-test-didi-ii.yml)
176+
177+
#### Push to Any Branch
178+
- [ ] Push commit to test branch
179+
- [ ] Verify pipeline triggers
180+
- [ ] **vortex-test-didi-database-ii job:**
181+
- [ ] Downloads DB from container registry
182+
- [ ] Creates DB image
183+
- [ ] Pushes image to registry
184+
- [ ] Uses custom cache key
185+
- [ ] **vortex-test-didi-build-ii job:**
186+
- [ ] Waits for database job
187+
- [ ] Restores cache with custom key
188+
- [ ] Builds site with DIDI image
189+
- [ ] Provisions successfully
190+
- [ ] Stores results
191+
192+
## Regression Testing
193+
194+
### 8. Compare Against Original config.yml
195+
196+
#### Job Behavior
197+
- [ ] All jobs from original config run correctly
198+
- [ ] Job dependencies are preserved
199+
- [ ] Conditional logic works as expected
200+
- [ ] Environment variables are accessible
201+
202+
#### Caching
203+
- [ ] Database cache keys match original
204+
- [ ] Cache restore works correctly
205+
- [ ] Cache save works correctly
206+
- [ ] Fallback caching works
207+
208+
#### Artifacts
209+
- [ ] Test results stored correctly
210+
- [ ] Artifacts stored correctly
211+
- [ ] Coverage reports uploaded
212+
213+
#### Timing
214+
- [ ] Build times are similar to original
215+
- [ ] No unexpected delays
216+
- [ ] Parallelism works correctly
217+
218+
### 9. Cross-Pipeline Independence
219+
220+
- [ ] Pipelines run independently
221+
- [ ] No cross-pipeline dependencies
222+
- [ ] Multiple pipelines can run simultaneously
223+
- [ ] Failures in one pipeline don't affect others
224+
225+
## Conditional Marker Testing
226+
227+
### 10. Verify Installer Processing
228+
229+
These tests verify that conditional markers will work correctly during installation:
230+
231+
#### !PROVISION_TYPE_PROFILE
232+
- [ ] Lines/sections marked are present in files
233+
- [ ] Will be correctly removed if profile provisioning is used
234+
235+
#### DEPLOYMENT
236+
- [ ] Deploy jobs are present in build-test-deploy.yml
237+
- [ ] Will be correctly removed if deployments are disabled
238+
239+
#### DEPS_UPDATE_PROVIDER_CI
240+
- [ ] update-dependencies.yml exists
241+
- [ ] Will be correctly removed if not using CI-based updates
242+
243+
#### VORTEX_DEV
244+
- [ ] vortex-test-*.yml files exist
245+
- [ ] Will be correctly removed during installation
246+
247+
#### TOOL_* Markers
248+
- [ ] PHPCS linting steps present
249+
- [ ] PHPStan linting steps present
250+
- [ ] Rector linting steps present
251+
- [ ] PHPMD linting steps present
252+
- [ ] Behat test steps present
253+
- [ ] PHPUnit test steps present
254+
255+
## Edge Cases and Error Handling
256+
257+
### 11. Error Scenarios
258+
259+
#### Missing Environment Variables
260+
- [ ] Pipeline fails gracefully if RENOVATE_TOKEN missing
261+
- [ ] Appropriate error messages displayed
262+
263+
#### SSH Key Issues
264+
- [ ] Pipeline fails if SSH key not configured
265+
- [ ] Error messages indicate missing key
266+
267+
#### Cache Miss
268+
- [ ] Pipeline handles missing cache gracefully
269+
- [ ] Fallback caching works correctly
270+
271+
#### Failed Tests
272+
- [ ] Build continues even if linters fail (with ignore flags)
273+
- [ ] Tests can be retried (Behat rerun)
274+
275+
## Performance Testing
276+
277+
### 12. Performance Validation
278+
279+
- [ ] Build times within acceptable range
280+
- [ ] Parallel jobs utilize parallelism correctly
281+
- [ ] Caching reduces build time significantly
282+
- [ ] Multiple pipelines don't slow each other down
283+
284+
## Documentation Validation
285+
286+
### 13. Documentation Accuracy
287+
288+
- [ ] README.md accurately describes all pipelines
289+
- [ ] Pipeline names match documentation
290+
- [ ] Trigger configurations match documentation
291+
- [ ] Environment variables list is complete
292+
- [ ] Configuration steps are accurate
293+
294+
## Final Validation
295+
296+
### 14. Production Readiness
297+
298+
- [ ] All pipelines tested successfully
299+
- [ ] No regressions from original config
300+
- [ ] Documentation is complete and accurate
301+
- [ ] Conditional markers preserved correctly
302+
- [ ] Installer compatibility verified (Phase 7)
303+
304+
---
305+
306+
## Test Results Summary
307+
308+
| Test Section | Status | Notes |
309+
|--------------|--------|-------|
310+
| 1. Pipeline Configuration | ⬜ Pending | |
311+
| 2. Main Pipeline | ⬜ Pending | |
312+
| 3. Database Nightly | ⬜ Pending | |
313+
| 4. Update Dependencies | ⬜ Pending | |
314+
| 5. Vortex Post-Build | ⬜ Pending | |
315+
| 6. Vortex DIDI-FI | ⬜ Pending | |
316+
| 7. Vortex DIDI-II | ⬜ Pending | |
317+
| 8. Regression Testing | ⬜ Pending | |
318+
| 9. Cross-Pipeline | ⬜ Pending | |
319+
| 10. Conditional Markers | ⬜ Pending | |
320+
| 11. Error Scenarios | ⬜ Pending | |
321+
| 12. Performance | ⬜ Pending | |
322+
| 13. Documentation | ⬜ Pending | |
323+
| 14. Production Readiness | ⬜ Pending | |
324+
325+
---
326+
327+
## Notes and Issues
328+
329+
Use this section to document any issues encountered during testing:
330+
331+
```
332+
Date: _______________
333+
Tester: _____________
334+
335+
Issues Found:
336+
1.
337+
2.
338+
3.
339+
340+
Resolution:
341+
1.
342+
2.
343+
3.
344+
```

0 commit comments

Comments
 (0)