1
0
mirror of https://github.com/laurent22/joplin.git synced 2025-11-26 22:41:17 +02:00

Desktop: Resolves #11687: Plugins: Allow editor plugins to support multiple windows (#12041)

This commit is contained in:
Henry Heino
2025-06-06 02:00:47 -07:00
committed by GitHub
parent 291ba88224
commit 608dbab453
46 changed files with 1022 additions and 195 deletions

View File

@@ -70,17 +70,20 @@ export const test = base.extend<JoplinFixtures>({
// See https://github.com/microsoft/playwright/issues/8798
//
// eslint-disable-next-line no-empty-pattern
profileDirectory: async ({ }, use) => {
profileDirectory: async ({ }, use, testInfo) => {
const profilePath = resolve(join(testDir, 'test-profile'));
const profileSubdir = join(profilePath, uuid.createNano());
await mkdirp(profileSubdir);
await use(profileSubdir);
// For debugging purposes, attach the Joplin log file to the test:
await attachJoplinLog(profileSubdir, testInfo);
await remove(profileSubdir);
},
electronApp: async ({ profileDirectory }, use, testInfo) => {
electronApp: async ({ profileDirectory }, use) => {
const startupArgs = createStartupArgs(profileDirectory);
const electronApp = await electron.launch({ args: startupArgs });
const startupPromise = waitForAppLoaded(electronApp);
@@ -89,9 +92,6 @@ export const test = base.extend<JoplinFixtures>({
await use(electronApp);
// For debugging purposes, attach the Joplin log file to the test:
await attachJoplinLog(profileDirectory, testInfo);
await electronApp.firstWindow();
await electronApp.close();
},