mirror of
https://github.com/zulip/zulip-desktop.git
synced 2025-10-23 03:31:56 +00:00
tests: Move tests/package.json to its own folder.
Signed-off-by: Anders Kaseorg <anders@zulip.com>
This commit is contained in:
@@ -10,7 +10,10 @@ const testsPackage = z
|
|||||||
.object({productName: z.string()})
|
.object({productName: z.string()})
|
||||||
.parse(
|
.parse(
|
||||||
JSON.parse(
|
JSON.parse(
|
||||||
fs.readFileSync(new URL("package.json", import.meta.url), "utf8"),
|
fs.readFileSync(
|
||||||
|
new URL("zulip-test/package.json", import.meta.url),
|
||||||
|
"utf8",
|
||||||
|
),
|
||||||
),
|
),
|
||||||
);
|
);
|
||||||
|
|
||||||
@@ -18,7 +21,7 @@ const testsPackage = z
|
|||||||
// Returns a promise that resolves to an Electron Application once the app has loaded.
|
// Returns a promise that resolves to an Electron Application once the app has loaded.
|
||||||
export async function createApp(): Promise<ElectronApplication> {
|
export async function createApp(): Promise<ElectronApplication> {
|
||||||
return _electron.launch({
|
return _electron.launch({
|
||||||
args: [import.meta.dirname], // Ensure this dir has a package.json file with a 'main' entry point
|
args: [path.join(import.meta.dirname, "zulip-test")], // Ensure this dir has a package.json file with a 'main' entry point
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@@ -2,5 +2,5 @@
|
|||||||
"version": "5.9.3",
|
"version": "5.9.3",
|
||||||
"productName": "ZulipTest",
|
"productName": "ZulipTest",
|
||||||
"type": "module",
|
"type": "module",
|
||||||
"main": "../dist-electron/index.cjs"
|
"main": "../../dist-electron/index.cjs"
|
||||||
}
|
}
|
@@ -164,11 +164,5 @@ const xoConfig: FlatXoConfig = [
|
|||||||
],
|
],
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
{
|
|
||||||
files: ["tests/**"],
|
|
||||||
rules: {
|
|
||||||
"n/no-extraneous-import": "off", // https://github.com/eslint-community/eslint-plugin-n/issues/209
|
|
||||||
},
|
|
||||||
},
|
|
||||||
];
|
];
|
||||||
export default xoConfig;
|
export default xoConfig;
|
||||||
|
Reference in New Issue
Block a user