(pattern: string)
| 29 | /** Sandbox code that creates a policy through the gated core tool. The pattern |
| 30 | * is unique-per-run and matches no real tool, so the rule is inert. */ |
| 31 | const createPolicyCode = (pattern: string) => ` |
| 32 | const result = await tools.executor.coreTools.policies.create({ |
| 33 | owner: "user", |
| 34 | pattern: ${JSON.stringify(pattern)}, |
| 35 | action: "block", |
| 36 | }); |
| 37 | return JSON.stringify(result); |
| 38 | `; |
| 39 | |
| 40 | scenario( |
| 41 | "Policy tools · policies.create pauses for approval from its own annotation, then runs once approved", |
no outgoing calls
no test coverage detected