@camunda/e2e-test-suite 0.0.1457 → 0.0.1459
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -37,6 +37,7 @@ declare class AppsPage {
|
|
|
37
37
|
private assertHubClusterAppPresent;
|
|
38
38
|
clickCluster(component: Locator, name: string): Promise<void>;
|
|
39
39
|
goBackToHub(): Promise<void>;
|
|
40
|
+
private dismissWelcomeTourIfVisible;
|
|
40
41
|
clickModeler(): Promise<void>;
|
|
41
42
|
private isModelerAuthTransit;
|
|
42
43
|
openModelerWithRetry(banner: Locator, timeout?: number, maxRetries?: number, ready?: Locator, beforeReady?: () => Promise<void>): Promise<void>;
|
|
@@ -343,6 +343,19 @@ class AppsPage {
|
|
|
343
343
|
await this.page.goto(this.hubReturnUrl);
|
|
344
344
|
}
|
|
345
345
|
}
|
|
346
|
+
// The "Welcome to Camunda Hub" onboarding tour renders as a modal dialog
|
|
347
|
+
// (heading + "Next"/"Close" buttons) that marks the rest of the shell inert.
|
|
348
|
+
// Close it when present so a header or sidebar lookup underneath it can
|
|
349
|
+
// resolve; a no-op when the tour never opened.
|
|
350
|
+
async dismissWelcomeTourIfVisible() {
|
|
351
|
+
const tour = this.page.getByRole('dialog', {
|
|
352
|
+
name: 'Welcome to Camunda Hub',
|
|
353
|
+
});
|
|
354
|
+
if (await tour.isVisible().catch(() => false)) {
|
|
355
|
+
await tour.getByRole('button', { name: 'Close' }).click({ timeout: 10000 });
|
|
356
|
+
await (0, test_1.expect)(tour).toBeHidden({ timeout: 10000 });
|
|
357
|
+
}
|
|
358
|
+
}
|
|
346
359
|
async clickModeler() {
|
|
347
360
|
const maxRetries = 5;
|
|
348
361
|
const modelerErrorPage = this.page
|
|
@@ -384,7 +397,17 @@ class AppsPage {
|
|
|
384
397
|
.getByRole('link', { name: 'Camunda Hub home' })
|
|
385
398
|
.and(this.page.locator(':not([href$="/login"])')))
|
|
386
399
|
.first();
|
|
387
|
-
|
|
400
|
+
// The "Welcome to Camunda Hub" onboarding tour can still mount over the
|
|
401
|
+
// shell despite the localStorage flag seeded at login (see
|
|
402
|
+
// suppressOnboardingTour in UtilitiesPage, whose key prefix the current
|
|
403
|
+
// hub build no longer reads) and marks the header inert, so the home link
|
|
404
|
+
// leaves the accessibility tree until the dialog is dismissed. Close it
|
|
405
|
+
// each interval so a tour that mounts a beat after routing is still
|
|
406
|
+
// cleared, the same way openModelerWithRetry's beforeReady loop does.
|
|
407
|
+
await (0, test_1.expect)(async () => {
|
|
408
|
+
await this.dismissWelcomeTourIfVisible();
|
|
409
|
+
await (0, test_1.expect)(homeLink).toBeVisible({ timeout: 15000 });
|
|
410
|
+
}).toPass({ timeout: 30000, intervals: [1000, 2000, 5000] });
|
|
388
411
|
await homeLink.click({ timeout: 30000 });
|
|
389
412
|
return;
|
|
390
413
|
}
|
|
@@ -10,6 +10,7 @@ declare class TaskPanelPage {
|
|
|
10
10
|
readonly expandButton: Locator;
|
|
11
11
|
readonly processesInfoText: Locator;
|
|
12
12
|
constructor(page: Page);
|
|
13
|
+
waitForTasklistLoaded(timeout?: number): Promise<void>;
|
|
13
14
|
openTask(name: string, taskKeys?: string[]): Promise<void>;
|
|
14
15
|
filterBy(option: 'All open' | 'Unassigned' | 'Assigned to me' | 'Completed'): Promise<void>;
|
|
15
16
|
taskCount(name: string): Promise<number>;
|
|
@@ -30,6 +30,27 @@ class TaskPanelPage {
|
|
|
30
30
|
});
|
|
31
31
|
this.processesInfoText = page.getByText('Browse and run processes published by your organization');
|
|
32
32
|
}
|
|
33
|
+
// Tasklist renders its route error page ("Something went wrong") when its
|
|
34
|
+
// lazily loaded JS chunks 404 -- seen on the AWS cluster when index.html
|
|
35
|
+
// and the asset chunks came from different builds. A reload fetches a
|
|
36
|
+
// consistent shell + chunks; the banner assertion itself is unchanged.
|
|
37
|
+
async waitForTasklistLoaded(timeout = 120000) {
|
|
38
|
+
const errorPage = this.page.getByRole('heading', {
|
|
39
|
+
name: 'Something went wrong',
|
|
40
|
+
});
|
|
41
|
+
const maxReloads = 3;
|
|
42
|
+
for (let attempt = 1; attempt <= maxReloads; attempt++) {
|
|
43
|
+
await (0, test_1.expect)(this.taskListPageBanner.or(errorPage).first()).toBeVisible({
|
|
44
|
+
timeout,
|
|
45
|
+
});
|
|
46
|
+
if (await this.taskListPageBanner.isVisible()) {
|
|
47
|
+
return;
|
|
48
|
+
}
|
|
49
|
+
console.warn(`Tasklist failed to load (attempt ${attempt}/${maxReloads}), reloading`);
|
|
50
|
+
await this.page.reload();
|
|
51
|
+
}
|
|
52
|
+
await (0, test_1.expect)(this.taskListPageBanner).toBeVisible({ timeout });
|
|
53
|
+
}
|
|
33
54
|
async openTask(name, taskKeys) {
|
|
34
55
|
let attempts = 0;
|
|
35
56
|
// Tasklist's importer can lag well behind Zeebe under heavy concurrent
|
|
@@ -94,9 +94,7 @@ _8_8_1.test.describe('AWS Cluster User Flows Test', () => {
|
|
|
94
94
|
await _8_8_1.test.step('Navigate to Tasklist and Assert Document Upload And Preview', async () => {
|
|
95
95
|
await appsPage.clickCamundaApps();
|
|
96
96
|
await appsPage.clickTasklist(clusterName);
|
|
97
|
-
await
|
|
98
|
-
timeout: 120000,
|
|
99
|
-
});
|
|
97
|
+
await taskPanelPage.waitForTasklistLoaded();
|
|
100
98
|
await taskPanelPage.openTask(processName);
|
|
101
99
|
await taskDetailsPage.clickAssignToMeButton();
|
|
102
100
|
await (0, fileUpload_1.uploadFile)(page, [
|