@camunda/e2e-test-suite 0.0.1127 → 0.0.1129
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.
|
@@ -18,6 +18,9 @@ declare class ModelerHomePage {
|
|
|
18
18
|
readonly workspaceWizardSubmit: Locator;
|
|
19
19
|
readonly workspaceMembersHeading: Locator;
|
|
20
20
|
readonly projectNameInput: Locator;
|
|
21
|
+
readonly workspaceWizardNameInput: Locator;
|
|
22
|
+
readonly workspaceWizardSubmitButton: Locator;
|
|
23
|
+
readonly workspaceWizardMembersStep: Locator;
|
|
21
24
|
readonly moreActionsButton: Locator;
|
|
22
25
|
readonly renameMenuItem: Locator;
|
|
23
26
|
readonly renameInput: Locator;
|
|
@@ -46,6 +49,7 @@ declare class ModelerHomePage {
|
|
|
46
49
|
constructor(page: Page);
|
|
47
50
|
clickCreateNewProjectButton(): Promise<void>;
|
|
48
51
|
enterNewProjectName(name: string): Promise<void>;
|
|
52
|
+
private createWorkspaceViaWizard;
|
|
49
53
|
waitForModelerReady(timeoutMs?: number): Promise<void>;
|
|
50
54
|
createCrossComponentProjectFolder(): Promise<void>;
|
|
51
55
|
clickCrossComponentProjectFolder(): Promise<void>;
|
|
@@ -45,6 +45,9 @@ class ModelerHomePage {
|
|
|
45
45
|
workspaceWizardSubmit;
|
|
46
46
|
workspaceMembersHeading;
|
|
47
47
|
projectNameInput;
|
|
48
|
+
workspaceWizardNameInput;
|
|
49
|
+
workspaceWizardSubmitButton;
|
|
50
|
+
workspaceWizardMembersStep;
|
|
48
51
|
moreActionsButton;
|
|
49
52
|
renameMenuItem;
|
|
50
53
|
renameInput;
|
|
@@ -96,6 +99,14 @@ class ModelerHomePage {
|
|
|
96
99
|
exact: true,
|
|
97
100
|
}));
|
|
98
101
|
this.projectNameInput = page.locator('[data-test="editable-input"]');
|
|
102
|
+
// The Design System shell no longer creates an empty project and renames it
|
|
103
|
+
// inline; "Create workspace" opens a two-step wizard (General -> Members)
|
|
104
|
+
// that names the workspace up front. The name lives on the General step, and
|
|
105
|
+
// the submit button keeps this test id across both steps ("Next" on General,
|
|
106
|
+
// "Create workspace" on Members).
|
|
107
|
+
this.workspaceWizardNameInput = page.locator('#workspace-name');
|
|
108
|
+
this.workspaceWizardSubmitButton = page.locator('[data-test="workspace-wizard-submit"]');
|
|
109
|
+
this.workspaceWizardMembersStep = page.locator('[data-test="step-members"]');
|
|
99
110
|
// The rename kebab sits beside the breadcrumb in the app header. The
|
|
100
111
|
// editor's action bar is a <header> too, so it also carries the banner
|
|
101
112
|
// role -- getByRole('banner') alone matches three headers in the editor
|
|
@@ -172,7 +183,16 @@ class ModelerHomePage {
|
|
|
172
183
|
this.licenseKeyTagCommercial = page.getByText('Commercial license');
|
|
173
184
|
this.uploadFilesButton = page.getByRole('menuitem', { name: 'Upload files' });
|
|
174
185
|
this.messageBanner = page.locator('[data-test="close-top-banner"]');
|
|
175
|
-
|
|
186
|
+
// The "New features" release modal is a Carbon ComposedModal. When it opens
|
|
187
|
+
// over another always-rendered modal its wrapper carries aria-hidden="true",
|
|
188
|
+
// which drops its buttons from the accessibility tree -- getByRole then never
|
|
189
|
+
// matches and the modal is never dismissed, deadlocking waitForModelerReady.
|
|
190
|
+
// Fall back to a CSS `button` locator (which ignores the accessibility tree)
|
|
191
|
+
// so the visible-but-aria-hidden dismiss control is still found and clicked.
|
|
192
|
+
this.closeButton = page
|
|
193
|
+
.getByRole('button', { name: 'Got it - Dismiss' })
|
|
194
|
+
.or(page.locator('button').filter({ hasText: 'Got it - Dismiss' }))
|
|
195
|
+
.first();
|
|
176
196
|
this.modalCloseButton = page.locator('.cds--modal.is-visible .cds--modal-close');
|
|
177
197
|
// exact:true — the Workspaces overview "Create workspace" split button has a
|
|
178
198
|
// sibling options chevron whose name would otherwise substring-match.
|
|
@@ -222,8 +242,16 @@ class ModelerHomePage {
|
|
|
222
242
|
async enterNewProjectName(name) {
|
|
223
243
|
await this.projectNameInput
|
|
224
244
|
.or(this.moreActionsButton)
|
|
245
|
+
.or(this.workspaceWizardNameInput)
|
|
225
246
|
.first()
|
|
226
247
|
.waitFor({ state: 'visible', timeout: 30000 });
|
|
248
|
+
// Design System shell: "Create workspace" opens the creation wizard, which
|
|
249
|
+
// names the workspace on its first step, so there is no post-creation rename
|
|
250
|
+
// to perform. Check this before the inline branch — the wizard replaces it.
|
|
251
|
+
if (await this.workspaceWizardNameInput.isVisible()) {
|
|
252
|
+
await this.createWorkspaceViaWizard(name);
|
|
253
|
+
return;
|
|
254
|
+
}
|
|
227
255
|
// Inline first: when the Carbon shell renders it, it is the whole flow.
|
|
228
256
|
if (await this.projectNameInput.isVisible()) {
|
|
229
257
|
await this.projectNameInput.click({ timeout: 60000 });
|
|
@@ -233,6 +261,17 @@ class ModelerHomePage {
|
|
|
233
261
|
}
|
|
234
262
|
await this.renameViaMoreActions(name);
|
|
235
263
|
}
|
|
264
|
+
// Drives hub's two-step workspace-creation wizard. The name is entered on the
|
|
265
|
+
// General step, which enables "Next"; the Members step is optional and the
|
|
266
|
+
// second submit ("Create workspace") creates the workspace. Gate that second
|
|
267
|
+
// click on the Members step becoming active so the shared submit button is not
|
|
268
|
+
// clicked twice while still on General.
|
|
269
|
+
async createWorkspaceViaWizard(name) {
|
|
270
|
+
await this.workspaceWizardNameInput.fill(name);
|
|
271
|
+
await this.workspaceWizardSubmitButton.click({ timeout: 60000 });
|
|
272
|
+
await (0, test_1.expect)(this.workspaceWizardMembersStep).toHaveAttribute('data-state', 'active', { timeout: 30000 });
|
|
273
|
+
await this.workspaceWizardSubmitButton.click({ timeout: 60000 });
|
|
274
|
+
}
|
|
236
275
|
// Wait for the Modeler project workspace to become interactive. The caller
|
|
237
276
|
// arrives here via goToModeler(), which has already loaded and authenticated
|
|
238
277
|
// the app shell (banner visible). The nav banner mounts before the project
|