Skip to content

Commit 1d02ffc

Browse files
committed
test(runtime): serialisation control reads the JSON-encoded message
Claude-Session: https://claude.ai/code/session_01Q9PZ5Pzqcus4woVvTZwWNU Co-authored-by: Claude <noreply@anthropic.com>
1 parent 2a64b50 commit 1d02ffc

1 file changed

Lines changed: 3 additions & 1 deletion

File tree

‎packages/runtime/src/standalone-stack-url-refusal-credentials.test.ts‎

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,9 @@ function expectRefusedWithoutCredentials(err: Error): void {
7878
expect(err.constructor).toBe(Error);
7979
expect(err.cause).toBeUndefined();
8080
const everything = JSON.stringify(err, Object.getOwnPropertyNames(err));
81-
expect(everything).toContain(err.message);
81+
// Positive control: the serialisation really holds the message, so the
82+
// negative reads below read something.
83+
expect(everything).toContain(JSON.stringify(err.message));
8284
for (const placeholder of [USER, SECRET, TOKEN]) {
8385
expect(everything, `the refusal carries ${placeholder}`).not.toContain(placeholder);
8486
}

0 commit comments

Comments
 (0)