MCPcopy Create free account
hub / github.com/garrytan/gstack / decide

Function decide

test/gstack-decision.test.ts:29–34  ·  view source on GitHub ↗
(id: string, over: Partial<DecisionEvent> = {})

Source from the content-addressed store, hash-verified

27const PEM_SECRET = "-----BEGIN RSA PRIVATE KEY-----\nMIIEowIBAAKCAQEA\n-----END RSA PRIVATE KEY-----";
28
29function decide(id: string, over: Partial<DecisionEvent> = {}): DecisionEvent {
30 return {
31 id, kind: "decide", decision: `d-${id}`, scope: "repo",
32 date: over.date || `2026-01-01T00:00:0${id}Z`, source: "agent", ...over,
33 };
34}
35
36describe("validateDecide", () => {
37 it("accepts a well-formed decision and stamps id + date", () => {

Callers 1

Calls

no outgoing calls

Tested by

no test coverage detected