Skip to content

Build your personal knowledge base with Trilium Notes

fix(e2e): run server E2E tests with a single worker

Elian Doran920adf1d3194
diff --git a/apps/server/playwright.config.ts b/apps/server/playwright.config.ts
index b081bfb206..4a98afb3e8 100644
--- a/apps/server/playwright.config.ts
+++ b/apps/server/playwright.config.ts
@@ -26,6 +26,12 @@ export default createBaseConfig({
appDir: __dirname,
localTestDir: "e2e",
projectName: "server",
+ // All workers share a single server instance and user account, and some state is
+ // global to the account — e.g. the openNoteContexts option holding the open tabs.
+ // With parallel workers, every test that opens a note overwrites that state for the
+ // others, which chronically flaked "Tabs are restored in right order". Same setting
+ // as the standalone app, which runs the identical shared suite without flaking.
+ workers: 1,
webServer: !process.env.TRILIUM_DOCKER ? {
command: "pnpm start-prod-no-dir",
url: baseURL,