fix: export named DB utilities in petsExtendedFields test mock
pets.ts imports pets, appointments, and, eq, exists, or directly from "../db". The vi.mock factory only returned getDb, causing vitest to throw "No 'pets' export is defined" and 7 tests to get 400 instead of 201/200. Fix adds the missing named exports to the mock return object. Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
This commit is contained in:
@@ -161,6 +161,12 @@ vi.mock("../db", () => {
|
|||||||
update: () => makeUpdateChainable(),
|
update: () => makeUpdateChainable(),
|
||||||
delete: () => makeDeleteChainable(),
|
delete: () => makeDeleteChainable(),
|
||||||
}),
|
}),
|
||||||
|
pets,
|
||||||
|
appointments,
|
||||||
|
and,
|
||||||
|
eq,
|
||||||
|
exists,
|
||||||
|
or,
|
||||||
};
|
};
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user