@camunda/e2e-test-suite 0.0.1693 → 0.0.1695

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.
Files changed (29) hide show
  1. package/dist/fixtures/SM-8.10.d.ts +1 -0
  2. package/dist/fixtures/SM-8.10.js +36 -0
  3. package/dist/fixtures/SM-8.11.d.ts +1 -0
  4. package/dist/fixtures/SM-8.11.js +36 -0
  5. package/dist/fixtures/SM-8.8.d.ts +1 -0
  6. package/dist/fixtures/SM-8.8.js +36 -0
  7. package/dist/fixtures/SM-8.9.d.ts +1 -0
  8. package/dist/fixtures/SM-8.9.js +36 -0
  9. package/dist/pages/SM-8.10/KeycloakUtils.js +1 -0
  10. package/dist/pages/SM-8.10/ManagementIdentityPage.d.ts +1 -0
  11. package/dist/pages/SM-8.10/ManagementIdentityPage.js +9 -0
  12. package/dist/pages/SM-8.10/OCIdentityClusterVariablesPage.js +3 -1
  13. package/dist/pages/SM-8.10/OperateHomePage.js +4 -2
  14. package/dist/pages/SM-8.11/KeycloakUtils.js +1 -0
  15. package/dist/pages/SM-8.11/ManagementIdentityPage.d.ts +1 -0
  16. package/dist/pages/SM-8.11/ManagementIdentityPage.js +9 -0
  17. package/dist/pages/SM-8.11/OCIdentityClusterVariablesPage.js +3 -1
  18. package/dist/pages/SM-8.11/OperateHomePage.js +4 -2
  19. package/dist/pages/SM-8.9/OCIdentityClusterVariablesPage.js +3 -1
  20. package/dist/tests/8.10/optimize-api-tests.spec.js +78 -41
  21. package/dist/tests/8.10/optimize-collections-api.spec.js +4 -2
  22. package/dist/tests/8.10/optimize-sharing-alerts-export-api.spec.js +10 -5
  23. package/dist/tests/8.10/optimize-sharing-alerts-export-ui.spec.js +6 -3
  24. package/dist/tests/8.11/optimize-api-tests.spec.js +58 -29
  25. package/dist/tests/8.11/optimize-collections-api.spec.js +4 -2
  26. package/dist/tests/8.11/optimize-sharing-alerts-export-api.spec.js +10 -5
  27. package/dist/tests/8.11/optimize-sharing-alerts-export-ui.spec.js +6 -3
  28. package/package.json +1 -1
  29. package/playwright.config.ts +104 -0
@@ -72,6 +72,7 @@ type PlaywrightFixtures = {
72
72
  ocIdentityGroupsPage: OCIdentityGroupsPage;
73
73
  ocTenantPage: OCTenantPage;
74
74
  overrideTrackingScripts: void;
75
+ rewriteIdentityAssetsOnFirefox: void;
75
76
  };
76
77
  declare const test: import("@playwright/test").TestType<import("@playwright/test").PlaywrightTestArgs & import("@playwright/test").PlaywrightTestOptions & PlaywrightFixtures, import("@playwright/test").PlaywrightWorkerArgs & import("@playwright/test").PlaywrightWorkerOptions>;
77
78
  export { test };
@@ -172,5 +172,41 @@ const test = test_1.test.extend({
172
172
  auto: true,
173
173
  },
174
174
  ],
175
+ rewriteIdentityAssetsOnFirefox: [
176
+ async ({ context, browserName }, use) => {
177
+ // Management Identity serves root-relative assets and relies on its
178
+ // service worker to prefix every same-origin, non-document request with
179
+ // /identity. Playwright's Firefox does not hand those requests to the
180
+ // service worker once any context.route() is registered, so apply the
181
+ // same rewrite. Same recipe as fixtures/SM-8.7.ts.
182
+ if (browserName === 'firefox') {
183
+ await context.route('**/*', async (route) => {
184
+ const request = route.request();
185
+ let frameUrl;
186
+ try {
187
+ frameUrl = new URL(request.frame().url());
188
+ }
189
+ catch {
190
+ frameUrl = undefined;
191
+ }
192
+ const requestUrl = new URL(request.url());
193
+ if (!frameUrl ||
194
+ request.isNavigationRequest() ||
195
+ frameUrl.origin !== requestUrl.origin ||
196
+ !frameUrl.pathname.startsWith('/identity')) {
197
+ await route.fallback();
198
+ return;
199
+ }
200
+ await route.continue({
201
+ url: `${requestUrl.origin}/identity${requestUrl.pathname}${requestUrl.search}`,
202
+ });
203
+ });
204
+ }
205
+ await use();
206
+ },
207
+ {
208
+ auto: true,
209
+ },
210
+ ],
175
211
  });
176
212
  exports.test = test;
@@ -72,6 +72,7 @@ type PlaywrightFixtures = {
72
72
  ocIdentityGroupsPage: OCIdentityGroupsPage;
73
73
  ocTenantPage: OCTenantPage;
74
74
  overrideTrackingScripts: void;
75
+ rewriteIdentityAssetsOnFirefox: void;
75
76
  };
76
77
  declare const test: import("@playwright/test").TestType<import("@playwright/test").PlaywrightTestArgs & import("@playwright/test").PlaywrightTestOptions & PlaywrightFixtures, import("@playwright/test").PlaywrightWorkerArgs & import("@playwright/test").PlaywrightWorkerOptions>;
77
78
  export { test };
@@ -172,5 +172,41 @@ const test = test_1.test.extend({
172
172
  auto: true,
173
173
  },
174
174
  ],
175
+ rewriteIdentityAssetsOnFirefox: [
176
+ async ({ context, browserName }, use) => {
177
+ // Management Identity serves root-relative assets and relies on its
178
+ // service worker to prefix every same-origin, non-document request with
179
+ // /identity. Playwright's Firefox does not hand those requests to the
180
+ // service worker once any context.route() is registered, so apply the
181
+ // same rewrite. Same recipe as fixtures/SM-8.7.ts.
182
+ if (browserName === 'firefox') {
183
+ await context.route('**/*', async (route) => {
184
+ const request = route.request();
185
+ let frameUrl;
186
+ try {
187
+ frameUrl = new URL(request.frame().url());
188
+ }
189
+ catch {
190
+ frameUrl = undefined;
191
+ }
192
+ const requestUrl = new URL(request.url());
193
+ if (!frameUrl ||
194
+ request.isNavigationRequest() ||
195
+ frameUrl.origin !== requestUrl.origin ||
196
+ !frameUrl.pathname.startsWith('/identity')) {
197
+ await route.fallback();
198
+ return;
199
+ }
200
+ await route.continue({
201
+ url: `${requestUrl.origin}/identity${requestUrl.pathname}${requestUrl.search}`,
202
+ });
203
+ });
204
+ }
205
+ await use();
206
+ },
207
+ {
208
+ auto: true,
209
+ },
210
+ ],
175
211
  });
176
212
  exports.test = test;
@@ -76,6 +76,7 @@ type PlaywrightFixtures = {
76
76
  ocTenantPage: OCTenantPage;
77
77
  idpCreatePage: IdpCreatePage;
78
78
  overrideTrackingScripts: void;
79
+ rewriteIdentityAssetsOnFirefox: void;
79
80
  };
80
81
  declare const test: import("@playwright/test").TestType<import("@playwright/test").PlaywrightTestArgs & import("@playwright/test").PlaywrightTestOptions & PlaywrightFixtures, import("@playwright/test").PlaywrightWorkerArgs & import("@playwright/test").PlaywrightWorkerOptions>;
81
82
  export { test };
@@ -180,5 +180,41 @@ const test = test_1.test.extend({
180
180
  auto: true,
181
181
  },
182
182
  ],
183
+ rewriteIdentityAssetsOnFirefox: [
184
+ async ({ context, browserName }, use) => {
185
+ // Management Identity serves root-relative assets and relies on its
186
+ // service worker to prefix every same-origin, non-document request with
187
+ // /identity. Playwright's Firefox does not hand those requests to the
188
+ // service worker once any context.route() is registered, so apply the
189
+ // same rewrite. Same recipe as fixtures/SM-8.7.ts.
190
+ if (browserName === 'firefox') {
191
+ await context.route('**/*', async (route) => {
192
+ const request = route.request();
193
+ let frameUrl;
194
+ try {
195
+ frameUrl = new URL(request.frame().url());
196
+ }
197
+ catch {
198
+ frameUrl = undefined;
199
+ }
200
+ const requestUrl = new URL(request.url());
201
+ if (!frameUrl ||
202
+ request.isNavigationRequest() ||
203
+ frameUrl.origin !== requestUrl.origin ||
204
+ !frameUrl.pathname.startsWith('/identity')) {
205
+ await route.fallback();
206
+ return;
207
+ }
208
+ await route.continue({
209
+ url: `${requestUrl.origin}/identity${requestUrl.pathname}${requestUrl.search}`,
210
+ });
211
+ });
212
+ }
213
+ await use();
214
+ },
215
+ {
216
+ auto: true,
217
+ },
218
+ ],
183
219
  });
184
220
  exports.test = test;
@@ -76,6 +76,7 @@ type PlaywrightFixtures = {
76
76
  ocIdentityGroupsPage: OCIdentityGroupsPage;
77
77
  ocTenantPage: OCTenantPage;
78
78
  overrideTrackingScripts: void;
79
+ rewriteIdentityAssetsOnFirefox: void;
79
80
  };
80
81
  declare const test: import("@playwright/test").TestType<import("@playwright/test").PlaywrightTestArgs & import("@playwright/test").PlaywrightTestOptions & PlaywrightFixtures, import("@playwright/test").PlaywrightWorkerArgs & import("@playwright/test").PlaywrightWorkerOptions>;
81
82
  export { test };
@@ -180,5 +180,41 @@ const test = test_1.test.extend({
180
180
  auto: true,
181
181
  },
182
182
  ],
183
+ rewriteIdentityAssetsOnFirefox: [
184
+ async ({ context, browserName }, use) => {
185
+ // Management Identity serves root-relative assets and relies on its
186
+ // service worker to prefix every same-origin, non-document request with
187
+ // /identity. Playwright's Firefox does not hand those requests to the
188
+ // service worker once any context.route() is registered, so apply the
189
+ // same rewrite. Same recipe as fixtures/SM-8.7.ts.
190
+ if (browserName === 'firefox') {
191
+ await context.route('**/*', async (route) => {
192
+ const request = route.request();
193
+ let frameUrl;
194
+ try {
195
+ frameUrl = new URL(request.frame().url());
196
+ }
197
+ catch {
198
+ frameUrl = undefined;
199
+ }
200
+ const requestUrl = new URL(request.url());
201
+ if (!frameUrl ||
202
+ request.isNavigationRequest() ||
203
+ frameUrl.origin !== requestUrl.origin ||
204
+ !frameUrl.pathname.startsWith('/identity')) {
205
+ await route.fallback();
206
+ return;
207
+ }
208
+ await route.continue({
209
+ url: `${requestUrl.origin}/identity${requestUrl.pathname}${requestUrl.search}`,
210
+ });
211
+ });
212
+ }
213
+ await use();
214
+ },
215
+ {
216
+ auto: true,
217
+ },
218
+ ],
183
219
  });
184
220
  exports.test = test;
@@ -85,6 +85,7 @@ const createIdentityUser = async (navigationPage, managementIdentity, username)
85
85
  await managementIdentity.clickIdentityCheckbox();
86
86
  await managementIdentity.clickOrchestrationCheckbox();
87
87
  await managementIdentity.clickAddButton();
88
+ await managementIdentity.waitForRolesAssigned();
88
89
  };
89
90
  const createOCUser = async (navigationPage, ocIdentityHomePage, ocIdentityRolesPage, username) => {
90
91
  await navigationPage.goToOCAdmin();
@@ -31,6 +31,7 @@ declare class ManagementIdentityPage {
31
31
  clickConfirmDeleteButton(): Promise<void>;
32
32
  clickAssignRolesButton(): Promise<void>;
33
33
  clickAddButton(): Promise<void>;
34
+ waitForRolesAssigned(): Promise<void>;
34
35
  clickOptimizeCheckbox(): Promise<void>;
35
36
  clickModelerCheckbox(): Promise<void>;
36
37
  clickIdentityCheckbox(): Promise<void>;
@@ -145,6 +145,15 @@ class ManagementIdentityPage {
145
145
  async clickAddButton() {
146
146
  await this.addButton.click();
147
147
  }
148
+ // The role-assignment POSTs are only guaranteed to land once the assigned
149
+ // roles table shows them. Navigating away earlier aborts them on Firefox,
150
+ // where they go through a context.route() rather than Identity's service
151
+ // worker, and the user is then left without ManagementIdentity access.
152
+ async waitForRolesAssigned() {
153
+ await (0, test_1.expect)(this.page
154
+ .getByRole('table')
155
+ .getByText('Provides full access to Management Identity')).toBeVisible({ timeout: 60000 });
156
+ }
148
157
  async clickOptimizeCheckbox() {
149
158
  await this.optimizeCheckbox.click();
150
159
  }
@@ -73,7 +73,9 @@ class OCIdentityClusterVariablesPage {
73
73
  await this.editVariableButton(variableName).click();
74
74
  await (0, test_1.expect)(this.editMenuItem).toBeVisible();
75
75
  await this.editMenuItem.click();
76
- await (0, test_1.expect)(this.variableValueField).toBeVisible();
76
+ // Firefox renders Monaco's input as a zero-height textarea, which
77
+ // Playwright reports as hidden; the editor itself is asserted visible below.
78
+ await (0, test_1.expect)(this.variableValueField).toBeAttached();
77
79
  await (0, test_1.expect)(this.monacoEditor).toBeVisible();
78
80
  // Monaco editor doesn't respond reliably to clear()/fill() on the
79
81
  // hidden textarea. Use keyboard shortcuts to select-all and replace,
@@ -118,7 +118,8 @@ class OperateHomePage {
118
118
  // Pass only the OPENING quote: Monaco auto-closes it. Supplying both ends
119
119
  // yields `"updatedValue""` -- invalid JSON, and Apply rejects it exactly
120
120
  // like the per-character version did. Same recipe as
121
- // pages/c8Run-8.10/OperateHomePage.ts.
121
+ // pages/c8Run-8.10/OperateHomePage.ts. Firefox's textarea input does not
122
+ // auto-close, so it gets the closing quote explicitly.
122
123
  //
123
124
  // Select with Home + Shift+End rather than ControlOrMeta+A: headless
124
125
  // Chromium on macOS does not apply Meta+A as select-all inside Monaco's
@@ -127,7 +128,8 @@ class OperateHomePage {
127
128
  // every platform.
128
129
  await this.page.keyboard.press('Home');
129
130
  await this.page.keyboard.press('Shift+End');
130
- await this.page.keyboard.insertText(`"${newValue}`);
131
+ const isFirefox = this.page.context().browser()?.browserType().name() === 'firefox';
132
+ await this.page.keyboard.insertText(`"${newValue}${isFirefox ? '"' : ''}`);
131
133
  }
132
134
  async clickSaveVariableButton() {
133
135
  await this.applyButton.click();
@@ -85,6 +85,7 @@ const createIdentityUser = async (navigationPage, managementIdentity, username)
85
85
  await managementIdentity.clickIdentityCheckbox();
86
86
  await managementIdentity.clickOrchestrationCheckbox();
87
87
  await managementIdentity.clickAddButton();
88
+ await managementIdentity.waitForRolesAssigned();
88
89
  };
89
90
  const createOCUser = async (navigationPage, ocIdentityHomePage, ocIdentityRolesPage, username) => {
90
91
  await navigationPage.goToOCAdmin();
@@ -32,6 +32,7 @@ declare class ManagementIdentityPage {
32
32
  removeAssignedRole(accessToDelete: string | string[], reopenUserRoles: () => Promise<void>): Promise<void>;
33
33
  clickAssignRolesButton(): Promise<void>;
34
34
  clickAddButton(): Promise<void>;
35
+ waitForRolesAssigned(): Promise<void>;
35
36
  clickOptimizeCheckbox(): Promise<void>;
36
37
  clickModelerCheckbox(): Promise<void>;
37
38
  clickIdentityCheckbox(): Promise<void>;
@@ -191,6 +191,15 @@ class ManagementIdentityPage {
191
191
  async clickAddButton() {
192
192
  await this.addButton.click();
193
193
  }
194
+ // The role-assignment POSTs are only guaranteed to land once the assigned
195
+ // roles table shows them. Navigating away earlier aborts them on Firefox,
196
+ // where they go through a context.route() rather than Identity's service
197
+ // worker, and the user is then left without ManagementIdentity access.
198
+ async waitForRolesAssigned() {
199
+ await (0, test_1.expect)(this.page
200
+ .getByRole('table')
201
+ .getByText('Provides full access to Management Identity')).toBeVisible({ timeout: 60000 });
202
+ }
194
203
  async clickOptimizeCheckbox() {
195
204
  await this.optimizeCheckbox.click();
196
205
  }
@@ -73,7 +73,9 @@ class OCIdentityClusterVariablesPage {
73
73
  await this.editVariableButton(variableName).click();
74
74
  await (0, test_1.expect)(this.editMenuItem).toBeVisible();
75
75
  await this.editMenuItem.click();
76
- await (0, test_1.expect)(this.variableValueField).toBeVisible();
76
+ // Firefox renders Monaco's input as a zero-height textarea, which
77
+ // Playwright reports as hidden; the editor itself is asserted visible below.
78
+ await (0, test_1.expect)(this.variableValueField).toBeAttached();
77
79
  await (0, test_1.expect)(this.monacoEditor).toBeVisible();
78
80
  // Monaco editor doesn't respond reliably to clear()/fill() on the
79
81
  // hidden textarea. Use keyboard shortcuts to select-all and replace,
@@ -129,7 +129,8 @@ class OperateHomePage {
129
129
  // Pass only the OPENING quote: Monaco auto-closes it. Supplying both ends
130
130
  // yields `"updatedValue""` -- invalid JSON, and Apply rejects it exactly
131
131
  // like the per-character version did. Same recipe as
132
- // pages/c8Run-8.10/OperateHomePage.ts.
132
+ // pages/c8Run-8.10/OperateHomePage.ts. Firefox's textarea input does not
133
+ // auto-close, so it gets the closing quote explicitly.
133
134
  //
134
135
  // Select with Home + Shift+End rather than ControlOrMeta+A: headless
135
136
  // Chromium on macOS does not apply Meta+A as select-all inside Monaco's
@@ -138,7 +139,8 @@ class OperateHomePage {
138
139
  // every platform.
139
140
  await this.page.keyboard.press('Home');
140
141
  await this.page.keyboard.press('Shift+End');
141
- await this.page.keyboard.insertText(`"${newValue}`);
142
+ const isFirefox = this.page.context().browser()?.browserType().name() === 'firefox';
143
+ await this.page.keyboard.insertText(`"${newValue}${isFirefox ? '"' : ''}`);
142
144
  }
143
145
  async clickSaveVariableButton() {
144
146
  await this.applyButton.click();
@@ -58,7 +58,9 @@ class OCIdentityClusterVariablesPage {
58
58
  await this.editVariableButton(variableName, scope).click();
59
59
  await (0, test_1.expect)(this.editMenuItem).toBeVisible();
60
60
  await this.editMenuItem.click();
61
- await (0, test_1.expect)(this.variableValueField).toBeVisible();
61
+ // Firefox renders Monaco's input as a zero-height textarea, which
62
+ // Playwright reports as hidden; the editor itself is asserted visible below.
63
+ await (0, test_1.expect)(this.variableValueField).toBeAttached();
62
64
  await (0, test_1.expect)(this.monacoEditor).toBeVisible();
63
65
  await this.monacoEditor.click();
64
66
  // Monaco editor doesn't respond reliably to clear()/fill() on the