MCPcopy Create free account
hub / github.com/SethGammon/Citadel / makeCampaignFile

Function makeCampaignFile

scripts/integration-test.js:189–212  ·  view source on GitHub ↗
(name, status = 'active', phaseCount = 3, currentPhase = 1)

Source from the content-addressed store, hash-verified

187 return result;
188}
189
190function makeCampaignFile(name, status = 'active', phaseCount = 3, currentPhase = 1) {
191 return [
192 '---',
193 'version: 1',
194 `status: ${status}`,
195 `started: "${new Date().toISOString()}"`,
196 `direction: "Test campaign ${name}"`,
197 `phase_count: ${phaseCount}`,
198 `current_phase: ${currentPhase}`,
199 '---',
200 '',
201 `# Campaign: ${name}`,
202 '',
203 `Status: ${status}`,
204 '',
205 '## Claimed Scope',
206 '- src/',
207 '',
208 '## Phases',
209 '| # | Status | Type | Phase | Done When |',
210 '|---|--------|------|-------|-----------|',
211 ...Array.from({ length: phaseCount }, (_, i) => `| ${i+1} | ${i === currentPhase-1 ? 'in-progress' : 'pending'} | build | Phase ${i+1} | done |`),
212 ].join('\n');
213}
214
215// ── Test runner ────────────────────────────────────────────────────────────────

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected