Skip to content

Commit 4f41fbf

Browse files
committed
test(cli): the os db orphans restrict-dependent row belongs to the seeded organization, as a NOT NULL tenant column requires
The raw knex write is not stamped, so it names the organization the case's other rows carry. No assertion changed. Claude-Session: https://claude.ai/code/session_018EszgtA3V2KXBX5tf59Hi4 Co-authored-by: Claude <noreply@anthropic.com>
1 parent 3e1df7f commit 4f41fbf

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

‎packages/cli/src/commands/db/orphans.integration.test.ts‎

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -352,10 +352,11 @@ describe('[#24964] os db orphans --delete — the delete is the engine\'s own',
352352
it('a restrict dependent refuses the orphan\'s delete, and nothing of its cascade is removed', async () => {
353353
const c = prepareCase();
354354
const exportPath = join(c.caseDir, 'export.json');
355-
// A row outside the cascade that holds the orphan through a `restrict` lookup.
355+
// A row outside the cascade that holds the orphan through a `restrict` lookup,
356+
// in the organization the seeded rows belong to (a raw write is not stamped).
356357
const driver = new SqlDriver({ client: 'better-sqlite3', connection: { filename: c.dbFile }, useNullAsDefault: true });
357358
try {
358-
await (driver as any).knex('od_hold').insert({ id: 'h_row', name: 'holds it', member: 'm_orphan' });
359+
await (driver as any).knex('od_hold').insert({ id: 'h_row', name: 'holds it', member: 'm_orphan', ...ORG });
359360
} finally {
360361
await driver.disconnect();
361362
}

0 commit comments

Comments
 (0)