From 90bdfe54e19da39bdb7d61c1872b109c5cfa7865 Mon Sep 17 00:00:00 2001 From: Johannes Millan Date: Tue, 20 Jan 2026 19:20:31 +0100 Subject: [PATCH] fix(e2e): dismiss welcome tour in archive sync test The test was failing because the Welcome tour dialog was blocking the "Finish Day" button click. Added dismissTourIfVisible() helper before archiving operations to prevent this. Also updated operation-applier.service.ts to remove the yield after dispatching remoteArchiveDataApplied since the effect that listened to this action has been disabled. Current status: - Test progresses past both clients archiving successfully - Tour dialog no longer blocks UI interactions - Still investigating timeout at final state verification --- e2e/tests/sync/webdav-sync-archive.spec.ts | 4 ++++ src/app/op-log/apply/operation-applier.service.ts | 6 +++--- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/e2e/tests/sync/webdav-sync-archive.spec.ts b/e2e/tests/sync/webdav-sync-archive.spec.ts index fd624a95c..b32da37a8 100644 --- a/e2e/tests/sync/webdav-sync-archive.spec.ts +++ b/e2e/tests/sync/webdav-sync-archive.spec.ts @@ -13,6 +13,7 @@ import { generateSyncFolderName, waitForArchivePersistence, } from '../../utils/sync-helpers'; +import { dismissTourIfVisible } from '../../utils/tour-helpers'; /** * WebDAV Archive Sync E2E Tests @@ -30,6 +31,9 @@ import { * Adapted from supersync-archive-subtasks.spec.ts */ const archiveDoneTasks = async (page: Page): Promise => { + // Dismiss any tour dialogs that might block the finish day button + await dismissTourIfVisible(page); + // Click finish day button const finishDayBtn = page.locator('.e2e-finish-day'); await finishDayBtn.waitFor({ state: 'visible', timeout: 10000 }); diff --git a/src/app/op-log/apply/operation-applier.service.ts b/src/app/op-log/apply/operation-applier.service.ts index f692abcdf..7374c8fa8 100644 --- a/src/app/op-log/apply/operation-applier.service.ts +++ b/src/app/op-log/apply/operation-applier.service.ts @@ -100,11 +100,11 @@ export class OperationApplierService { return archiveResult; } - // Trigger archive reload for UI if archive-affecting operations were applied + // Dispatch action to signal archive data was applied (for potential future use) + // Note: The refreshWorklogAfterRemoteArchiveOps effect that used to listen to + // this action is now disabled to prevent UI freezes during bulk archive sync. if (archiveResult.hadArchiveAffectingOp) { this.store.dispatch(remoteArchiveDataApplied()); - // Yield to let the remoteArchiveDataApplied effect run (refreshWorklog) - await new Promise((resolve) => setTimeout(resolve, 0)); } } } finally {