Skip to content

Commit 3a0c663

Browse files
committed
fix: increase file explorer visibility timeout to fix flaky test
The test was failing on macOS CI because it only waited 2 seconds for the .vscode folder to appear in file explorer. This increases the timeout to 10 seconds using the new TimeoutConstants.FILE_EXPLORER_TIMEOUT constant.
1 parent 3166fe0 commit 3a0c663

2 files changed

Lines changed: 7 additions & 1 deletion

File tree

test/smoke/suites/helper/componentHelper.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,10 @@ export class ComponentHelper {
6464
fileName: string,
6565
): Promise<ElementHandle<SVGElement | HTMLElement> | null> {
6666
try {
67-
return await ElementHelper.WaitElementAriaLabelVisible(fileName, 2000);
67+
return await ElementHelper.WaitElementAriaLabelVisible(
68+
fileName,
69+
TimeoutConstants.FILE_EXPLORER_TIMEOUT,
70+
);
6871
} catch {
6972
return null;
7073
}

test/smoke/suites/helper/timeoutConstants.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,7 @@ export class TimeoutConstants {
2626

2727
/** Packager state change timeout - 3 minutes (180 seconds) */
2828
static readonly PACKAGER_STATE_TIMEOUT = 180000;
29+
30+
/** File explorer element visibility timeout - 10 seconds */
31+
static readonly FILE_EXPLORER_TIMEOUT = 10000;
2932
}

0 commit comments

Comments
 (0)