mirror of
https://github.com/openclaw/openclaw.git
synced 2026-03-19 22:10:51 +00:00
Fix windows ACL os mock typing
This commit is contained in:
@@ -5,10 +5,11 @@ const MOCK_USERNAME = "MockUser";
|
||||
|
||||
vi.mock("node:os", async (importOriginal) => {
|
||||
const actual = await importOriginal<typeof import("node:os")>();
|
||||
const base = ("default" in actual ? actual.default : actual) as Record<string, unknown>;
|
||||
return {
|
||||
...actual,
|
||||
default: {
|
||||
...actual.default,
|
||||
...base,
|
||||
userInfo: () => ({ username: MOCK_USERNAME }),
|
||||
},
|
||||
userInfo: () => ({ username: MOCK_USERNAME }),
|
||||
|
||||
Reference in New Issue
Block a user