mirror of
https://github.com/garrytan/gstack.git
synced 2026-11-10 10:40:32 +01:00
feat(contract): lanes run gstack-pregate (and the sealed guard where configured) before done; handoff carries the gstack trailer and PREGATE: line
The coordinator contract gains a 'Before done' paragraph and the handoff order GSTACK_RESULT, gstack: ok|fail <rev>, PREGATE:, gate summary; the spec section is regenerated and docs/unattended.md states the same rule. A new test pins the terms and their order; the byte-identity pins stay. Co-authored-by: capy-ai[bot] <230910855+capy-ai[bot]@users.noreply.github.com>
This commit is contained in:
1 parent
22737a8f66
commit
6aeea57aec
4 files changed
+26
-2
No files matched your search
@@ -129,6 +129,15 @@ describe('coordinator contract', () => {
|
||||
expect(rendered).toContain('gstack-autoplan contract) || {');
|
||||
});
|
||||
|
||||
test('field wave CD: a lane runs pregate (and the sealed guard where configured) before done; the handoff carries the gstack trailer and the PREGATE: line after GSTACK_RESULT', () => {
|
||||
expect(COORDINATOR_CONTRACT).toContain('`gstack-pregate run --allow-repo-commands`');
|
||||
expect(COORDINATOR_CONTRACT).toContain('`gstack-pregate sealed` before any push or PR creation');
|
||||
const handoff = COORDINATOR_CONTRACT.slice(COORDINATOR_CONTRACT.indexOf('Handoff format.'));
|
||||
const order = ['`GSTACK_RESULT` line', '`gstack: ok|fail <rev>` line', '`PREGATE:` line', 'gate summary'].map(t => handoff.indexOf(t));
|
||||
expect(order.every(i => i > 0)).toBe(true);
|
||||
expect([...order].sort((a, b) => a - b)).toEqual(order);
|
||||
});
|
||||
|
||||
test('both reviewer prompts carry the contract after the plan, labelled as data', async () => {
|
||||
const { writePrompts } = await import('../lib/autoplan-prompts');
|
||||
const dir = fs.mkdtempSync(path.join(require('node:os').tmpdir(), 'gstack-contract-'));
|
||||
|
||||
Reference in new issue
Block a user