@camunda/e2e-test-suite 0.0.1323 → 0.0.1325

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.
@@ -5,6 +5,7 @@ const test_1 = require("@playwright/test");
5
5
  const UtilitiesPage_1 = require("./UtilitiesPage");
6
6
  const authErrorClassification_1 = require("../../utils/authErrorClassification");
7
7
  const consoleApiHelpers_1 = require("../../utils/consoleApiHelpers");
8
+ const sessionRecovery_1 = require("../../utils/sessionRecovery");
8
9
  const userNameInputValidInputSchema = {
9
10
  _schema: {
10
11
  maxlength: 254,
@@ -95,6 +96,7 @@ class LoginPage {
95
96
  // the tab's whole lifetime; without clearing it here, a flow that logs a
96
97
  // different user into the same page could have getUserToken() return the
97
98
  // PREVIOUS user's token.
99
+ (0, sessionRecovery_1.trackSignedInUser)(this.page, username);
98
100
  (0, consoleApiHelpers_1.resetHubBearerToken)(this.page);
99
101
  await (0, test_1.expect)(this.usernameInput.locator).toBeVisible({ timeout: 200000 });
100
102
  await this.fillUsername(username);
@@ -151,6 +153,7 @@ class LoginPage {
151
153
  // See login() above: this re-authenticates the same page and must clear
152
154
  // the Hub bearer-token cache too, or getUserToken() can return the
153
155
  // previous user's cached token.
156
+ (0, sessionRecovery_1.trackSignedInUser)(this.page, username);
154
157
  (0, consoleApiHelpers_1.resetHubBearerToken)(this.page);
155
158
  // Skip navigation if the auth0 login page is already loaded — re-navigating
156
159
  // to '/' when already on auth0 undoes the redirect and causes a 60-second
@@ -198,6 +201,7 @@ class LoginPage {
198
201
  // See login() above: this re-authenticates the same page and must clear
199
202
  // the Hub bearer-token cache too, or getUserToken() can return the
200
203
  // previous user's cached token.
204
+ (0, sessionRecovery_1.trackSignedInUser)(this.page, username);
201
205
  (0, consoleApiHelpers_1.resetHubBearerToken)(this.page);
202
206
  await (0, test_1.expect)(this.usernameInput.locator).toBeVisible({ timeout: 180000 });
203
207
  await this.fillUsername(username);
@@ -861,6 +861,11 @@ class ModelerCreatePage {
861
861
  throw new Error(`runProcessInstance failed after ${maxRetries} attempts. Last error: ${error instanceof Error ? error.message : error}`);
862
862
  }
863
863
  await this.page.reload();
864
+ // A Hub backend failure (5xx on /api/internal/login) makes the SPA call
865
+ // Auth0 logout, so the reload lands on the login form and every
866
+ // remaining attempt would reload that form until the loop is spent.
867
+ // Sign back in as the same user; Auth0 returns to the diagram.
868
+ await (0, sessionRecovery_1.restoreSessionIfLoggedOut)(this.page);
864
869
  await this.page.waitForTimeout(retryDelayMs);
865
870
  }
866
871
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@camunda/e2e-test-suite",
3
- "version": "0.0.1323",
3
+ "version": "0.0.1325",
4
4
  "description": "End-to-end test helpers for Camunda 8",
5
5
  "repository": {
6
6
  "type": "git",