Skip to content

Commit 00e32ec

Browse files
committed
test(plugin-approvals): type the new pins' engine options instead of erasing them
Co-authored-by: Claude <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01WGufzeiHatzB4rRx1t4Php
1 parent a453d12 commit 00e32ec

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

‎packages/plugins/plugin-approvals/src/record-lock-read.integration.test.ts‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -450,7 +450,7 @@ describe('lockSource — which approval holds a locked row, the same at the sing
450450
/** The caller's delete, and the refusal code when it is refused. */
451451
async function deleteAs(rig: Rig, userId: string, object: string, recordId: string): Promise<string> {
452452
try {
453-
await rig.engine.delete(object, { where: { id: recordId }, context: asUser(userId) } as any);
453+
await rig.engine.delete(object, { where: { id: recordId }, context: asUser(userId) });
454454
return 'deleted';
455455
} catch (err: any) {
456456
return String(err?.code ?? err?.message);
@@ -561,7 +561,7 @@ describe('both lock reads count a row readable by one rule — a loosely matched
561561
caseInsensitiveIds(rig.engine, HELD);
562562
const loose = (id: string) => id.toUpperCase();
563563
// CONTROL — the engine does hand the row back under the loose spelling.
564-
const found = await rig.engine.find(LINE, { where: { id: loose(recordA(LINE)) }, fields: ['id'], context: SYSTEM } as any);
564+
const found = await rig.engine.find(LINE, { where: { id: loose(recordA(LINE)) }, fields: ['id'], context: SYSTEM });
565565
expect((found as any[]).map((row) => row.id)).toEqual([recordA(LINE)]);
566566

567567
expect(await rig.svc.getRecordLock(LINE, loose(recordA(LINE)), asUser(SUBMITTER))).toBeNull();

0 commit comments

Comments
 (0)