test: fix readonly typing regressions in check baseline

This commit is contained in:
Brian Mendonca
2026-02-21 15:11:56 -07:00
committed by Peter Steinberger
parent 0e1aa77928
commit c7c047287e
5 changed files with 39 additions and 16 deletions

View File

@@ -847,7 +847,9 @@ describe("normalizeOutboundPayloadsForJson", () => {
];
for (const testCase of cases) {
expect(normalizeOutboundPayloadsForJson(testCase.input)).toEqual(testCase.expected);
expect(
normalizeOutboundPayloadsForJson(testCase.input.map((payload) => ({ ...payload }))),
).toEqual(testCase.expected);
}
});
});
@@ -882,7 +884,13 @@ describe("formatOutboundPayloadLog", () => {
];
for (const testCase of cases) {
expect(formatOutboundPayloadLog(testCase.input), testCase.name).toBe(testCase.expected);
expect(
formatOutboundPayloadLog({
...testCase.input,
mediaUrls: [...testCase.input.mediaUrls],
}),
testCase.name,
).toBe(testCase.expected);
}
});
});