@camunda/e2e-test-suite 0.0.1199 → 0.0.1201
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.
|
@@ -293,13 +293,17 @@ class ModelerHomePage {
|
|
|
293
293
|
// "Create workspace" CTA (always present) plus an "Open workspace ..." tile
|
|
294
294
|
// per existing workspace — the legacy "Create new project" button never
|
|
295
295
|
// renders there, which is what used to time out. Gate on those overview
|
|
296
|
-
// markers
|
|
297
|
-
//
|
|
298
|
-
//
|
|
296
|
+
// markers, the projects-listing "Create project" CTA (landed on directly
|
|
297
|
+
// after creating a workspace, or after opening one that has no projects
|
|
298
|
+
// yet -- neither overview marker renders there), and the legacy flag-off
|
|
299
|
+
// home markers, so the wait resolves whichever shell the deployment
|
|
300
|
+
// renders. .first(): several can be present at once (e.g. the CTA and a
|
|
301
|
+
// tile), and waitFor() requires a single match.
|
|
299
302
|
const workspaceElement = this.createWorkspaceButton
|
|
300
303
|
.or(this.workspaceOpenButton)
|
|
301
304
|
.or(this.createNewProjectButton)
|
|
302
305
|
.or(this.crossComponentProjectFolder)
|
|
306
|
+
.or(this.processApplicationPage.createProcessApplicationButton)
|
|
303
307
|
.first();
|
|
304
308
|
// The "New features" release modal renders lazily over the Modeler home,
|
|
305
309
|
// and under the Design System shell the project list -- the "Create new
|
|
@@ -398,7 +402,10 @@ class ModelerHomePage {
|
|
|
398
402
|
.isVisible()
|
|
399
403
|
.catch(() => false);
|
|
400
404
|
if (!workspaceExists) {
|
|
405
|
+
// Creating the workspace lands the creator (a Workspace Admin) on its
|
|
406
|
+
// projects listing directly, so there is no tile to open afterwards.
|
|
401
407
|
await this.createWorkspace(this.defaultFolderName);
|
|
408
|
+
return;
|
|
402
409
|
}
|
|
403
410
|
await this.openWorkspaceTile();
|
|
404
411
|
return;
|
|
@@ -434,7 +441,8 @@ class ModelerHomePage {
|
|
|
434
441
|
// Walks the create-workspace wizard (`/workspaces/create`): fill the general
|
|
435
442
|
// step, advance to the members step, and submit with the creator only (the
|
|
436
443
|
// creator is pre-added as Workspace Admin, satisfying the "at least one admin"
|
|
437
|
-
// guard).
|
|
444
|
+
// guard). On success the hub routes the role-holding creator straight to the
|
|
445
|
+
// new workspace's projects listing, not back to the `/workspaces` overview. The
|
|
438
446
|
// single primary button relabels itself "Next" -> "Create workspace" between
|
|
439
447
|
// steps; match its stable data-test hook where present and fall back to the
|
|
440
448
|
// step-appropriate accessible name (the wizard route does not render the
|
|
@@ -458,9 +466,15 @@ class ModelerHomePage {
|
|
|
458
466
|
.or(this.page.getByRole('button', { name: 'Create workspace', exact: true }))
|
|
459
467
|
.first()
|
|
460
468
|
.click({ timeout: 30000 });
|
|
461
|
-
|
|
469
|
+
// submit-workspace routes a role-holding creator to the new workspace's
|
|
470
|
+
// projects listing (`/workspace(s)/{id}/projects`), not the `/workspaces`
|
|
471
|
+
// overview, so gate on that landing (singular or plural route).
|
|
472
|
+
await this.page.waitForURL(/\/workspaces?\/[^/]+\/projects/, {
|
|
473
|
+
timeout: 120000,
|
|
474
|
+
});
|
|
462
475
|
await this.waitForModelerReady();
|
|
463
|
-
this.
|
|
476
|
+
this.workspaceProjectsUrl = this.page.url();
|
|
477
|
+
await this.clickMessageBanner();
|
|
464
478
|
}
|
|
465
479
|
// Opens the shared Workspace's tile and waits until its projects listing has
|
|
466
480
|
// loaded, remembering that URL for later returns via clickWorkspaceBreadcrumb.
|
|
@@ -141,6 +141,7 @@ declare class ModelerCreatePage {
|
|
|
141
141
|
clickMarketPlaceButton(): Promise<void>;
|
|
142
142
|
completeDeploymentEndpointConfiguration(): Promise<void>;
|
|
143
143
|
completePlayConfiguration(): Promise<void>;
|
|
144
|
+
private searchAndClickWebhookConnector;
|
|
144
145
|
clickWebhookMessageStartEventConnectorOption(): Promise<void>;
|
|
145
146
|
clickWebhookIdInput(): Promise<void>;
|
|
146
147
|
clearWebhookIdInput(): Promise<void>;
|
|
@@ -718,22 +718,46 @@ class ModelerCreatePage {
|
|
|
718
718
|
}
|
|
719
719
|
}
|
|
720
720
|
}
|
|
721
|
+
async searchAndClickWebhookConnector() {
|
|
722
|
+
// The change-element popup virtualizes its list: connector templates render
|
|
723
|
+
// below the built-in BPMN start events and are not in the queryable DOM
|
|
724
|
+
// slice until the list is filtered. Type into the popup search box (the
|
|
725
|
+
// same `.djs-popup-search input` selector the bpmn-js/hub e2e tests use)
|
|
726
|
+
// so the Webhook Message Start Event Connector entry is rendered before
|
|
727
|
+
// asserting on it. Use pressSequentially (not fill): fill sets the value in
|
|
728
|
+
// one shot and the single input event can land before bpmn-js attaches its
|
|
729
|
+
// search handler during the popup re-render, leaving the list unfiltered so
|
|
730
|
+
// the off-screen connector entry never becomes visible.
|
|
731
|
+
await (0, test_1.expect)(this.changeElementSearchInput).toBeVisible({ timeout: 30000 });
|
|
732
|
+
await this.changeElementSearchInput.click();
|
|
733
|
+
await this.changeElementSearchInput.fill('');
|
|
734
|
+
await this.changeElementSearchInput.pressSequentially('Webhook', {
|
|
735
|
+
delay: 50,
|
|
736
|
+
});
|
|
737
|
+
await (0, test_1.expect)(this.webhookMessageStartEventConnectorOption).toBeVisible({
|
|
738
|
+
timeout: 90000,
|
|
739
|
+
});
|
|
740
|
+
await this.webhookMessageStartEventConnectorOption.click({ timeout: 90000 });
|
|
741
|
+
}
|
|
721
742
|
async clickWebhookMessageStartEventConnectorOption() {
|
|
722
743
|
const maxRetries = 3;
|
|
723
744
|
for (let retries = 0; retries < maxRetries; retries++) {
|
|
724
745
|
try {
|
|
725
|
-
if (retries
|
|
726
|
-
await this.webhookMessageStartEventConnectorOption.click({
|
|
727
|
-
timeout: 30000,
|
|
728
|
-
});
|
|
729
|
-
}
|
|
730
|
-
else {
|
|
746
|
+
if (retries > 0) {
|
|
731
747
|
await this.page.reload();
|
|
732
|
-
await this.changeTypeButton.click({ force: true, timeout: 30000 });
|
|
733
|
-
await this.webhookMessageStartEventConnectorOption.click({
|
|
734
|
-
timeout: 90000,
|
|
735
|
-
});
|
|
736
748
|
}
|
|
749
|
+
// The marketplace import closes the change-element popup, so it is
|
|
750
|
+
// routinely gone by the time this runs; reopen it against the start
|
|
751
|
+
// event before filtering so the popup search input is present.
|
|
752
|
+
const popupOpen = await this.changeElementSearchInput
|
|
753
|
+
.waitFor({ state: 'visible', timeout: retries > 0 ? 5000 : 2000 })
|
|
754
|
+
.then(() => true)
|
|
755
|
+
.catch(() => false);
|
|
756
|
+
if (!popupOpen) {
|
|
757
|
+
await this.clickStartEventElement();
|
|
758
|
+
await this.changeTypeButton.click({ force: true, timeout: 90000 });
|
|
759
|
+
}
|
|
760
|
+
await this.searchAndClickWebhookConnector();
|
|
737
761
|
return;
|
|
738
762
|
}
|
|
739
763
|
catch (error) {
|