@camunda/e2e-test-suite 0.0.1643 → 0.0.1645

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.
@@ -7,6 +7,9 @@ const expectLocatorWithRetry_1 = require("../../utils/assertionHelpers/expectLoc
7
7
  const clickLocatorWithRetry_1 = require("../../utils/assertionHelpers/clickLocatorWithRetry");
8
8
  const clusterVersions_1 = require("../../utils/clusterVersions");
9
9
  const consoleApiHelpers_1 = require("../../utils/consoleApiHelpers");
10
+ // Accessible name of a cloud-provider radio: the bare code ("GCP") or the
11
+ // full name ending with the code in parentheses ("Google Cloud (GCP)").
12
+ const providerName = (code) => new RegExp(`^(?:${code}|.*\\(${code}\\))$`);
10
13
  class ClusterPage {
11
14
  page;
12
15
  defaultClusterType = 'G3-Dev';
@@ -93,7 +96,11 @@ class ClusterPage {
93
96
  this.devTab = choice(page.getByRole('tab', { name: 'Internal Dev' }), 'Internal Dev');
94
97
  this.stableTab = choice(page.getByRole('tab', { name: 'Stable' }), 'Stable');
95
98
  this.qaGenerationsTab = choice(page.getByRole('tab', { name: 'QA Generations' }), 'QA Generations');
96
- this.gcpRegion = choice(page.getByRole('tab', { name: 'GCP' }), 'GCP');
99
+ // The provider radio was renamed from "GCP" to "Google Cloud (GCP)" (and
100
+ // "AWS" to "Amazon Web Services (AWS)"), so match either name.
101
+ this.gcpRegion = page
102
+ .getByRole('tab', { name: 'GCP' })
103
+ .or(page.getByRole('radio', { name: providerName('GCP') }));
97
104
  this.belgiumRegion = choice(page.locator('label').filter({
98
105
  hasText: 'Chaos, Belgium, Europe (europe-west1)',
99
106
  }), 'Chaos, Belgium, Europe (europe-west1)');
@@ -358,7 +365,7 @@ class ClusterPage {
358
365
  await this.clickClusterType();
359
366
  await this.page
360
367
  .getByRole('tab', { name: region })
361
- .or(this.page.getByRole('radio', { name: region, exact: true }))
368
+ .or(this.page.getByRole('radio', { name: providerName(region) }))
362
369
  .click();
363
370
  await this.selectSubRegion(region);
364
371
  await this.clickClusterOption(process.env.CLUSTER_VERSION);
@@ -1447,6 +1447,27 @@ class ModelerCreatePage {
1447
1447
  await (0, test_1.expect)(this.templateNotFoundTag).toBeHidden();
1448
1448
  }
1449
1449
  async assertExportedTemplateBindings(bindings) {
1450
+ // A transient background fetch (the file's comments load was seen to fail
1451
+ // once with net::ERR_FAILED, then succeed on retry) raises a sonner error
1452
+ // toast in the top-right corner, where the "Browse more actions" kebab also
1453
+ // sits. Its subtree then intercepts every click on the kebab for the full
1454
+ // action timeout even though the button is visible and enabled (trace:
1455
+ // `<li data-sonner-toast data-type="error"> intercepts pointer events`).
1456
+ // Dismiss any lingering error toast via its close button first; the
1457
+ // exported-XML assertion below is unaffected, so this clears the incidental
1458
+ // overlay without masking a real failure.
1459
+ const toast = this.page.locator('[data-sonner-toast][data-type="error"]');
1460
+ const toastClose = toast.locator('[data-close-button="true"]');
1461
+ for (let i = 0; i < 5; i++) {
1462
+ if (!(await toastClose
1463
+ .first()
1464
+ .isVisible()
1465
+ .catch(() => false)))
1466
+ break;
1467
+ const before = await toast.count();
1468
+ await toastClose.first().click();
1469
+ await (0, test_1.expect)(toast).toHaveCount(before - 1, { timeout: 5000 });
1470
+ }
1450
1471
  await this.page
1451
1472
  .getByRole('button', { name: 'Browse more actions', exact: true })
1452
1473
  .click();
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camunda/e2e-test-suite",
3
- "version": "0.0.1643",
3
+ "version": "0.0.1645",
4
4
  "description": "End-to-end test helpers for Camunda 8",
5
5
  "repository": {
6
6
  "type": "git",