@camunda/e2e-test-suite 0.0.1443 → 0.0.1445

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 (122) hide show
  1. package/.github/c8_versions.json +1 -0
  2. package/README.md +2 -0
  3. package/dist/fixtures/SM-8.11.d.ts +77 -0
  4. package/dist/fixtures/SM-8.11.js +176 -0
  5. package/dist/pages/SM-8.11/Authorization.d.ts +39 -0
  6. package/dist/pages/SM-8.11/Authorization.js +349 -0
  7. package/dist/pages/SM-8.11/ClusterDetailsPage.d.ts +8 -0
  8. package/dist/pages/SM-8.11/ClusterDetailsPage.js +65 -0
  9. package/dist/pages/SM-8.11/ClusterPage.d.ts +11 -0
  10. package/dist/pages/SM-8.11/ClusterPage.js +37 -0
  11. package/dist/pages/SM-8.11/ConnectorMarketplacePage.d.ts +27 -0
  12. package/dist/pages/SM-8.11/ConnectorMarketplacePage.js +187 -0
  13. package/dist/pages/SM-8.11/ConnectorSettingsPage.d.ts +41 -0
  14. package/dist/pages/SM-8.11/ConnectorSettingsPage.js +153 -0
  15. package/dist/pages/SM-8.11/ConnectorTemplatePage.d.ts +11 -0
  16. package/dist/pages/SM-8.11/ConnectorTemplatePage.js +34 -0
  17. package/dist/pages/SM-8.11/FormJsPage.d.ts +33 -0
  18. package/dist/pages/SM-8.11/FormJsPage.js +109 -0
  19. package/dist/pages/SM-8.11/HomePage.d.ts +20 -0
  20. package/dist/pages/SM-8.11/HomePage.js +49 -0
  21. package/dist/pages/SM-8.11/IdentityTenantPage.d.ts +53 -0
  22. package/dist/pages/SM-8.11/IdentityTenantPage.js +264 -0
  23. package/dist/pages/SM-8.11/IdentityUsersPage.d.ts +92 -0
  24. package/dist/pages/SM-8.11/IdentityUsersPage.js +485 -0
  25. package/dist/pages/SM-8.11/KeycloakAdminPage.d.ts +17 -0
  26. package/dist/pages/SM-8.11/KeycloakAdminPage.js +78 -0
  27. package/dist/pages/SM-8.11/KeycloakLoginPage.d.ts +12 -0
  28. package/dist/pages/SM-8.11/KeycloakLoginPage.js +32 -0
  29. package/dist/pages/SM-8.11/KeycloakUtils.d.ts +17 -0
  30. package/dist/pages/SM-8.11/KeycloakUtils.js +94 -0
  31. package/dist/pages/SM-8.11/LoginPage.d.ts +21 -0
  32. package/dist/pages/SM-8.11/LoginPage.js +112 -0
  33. package/dist/pages/SM-8.11/ManagementIdentityPage.d.ts +44 -0
  34. package/dist/pages/SM-8.11/ManagementIdentityPage.js +176 -0
  35. package/dist/pages/SM-8.11/ModelerCreatePage.d.ts +238 -0
  36. package/dist/pages/SM-8.11/ModelerCreatePage.js +1950 -0
  37. package/dist/pages/SM-8.11/ModelerHomePage.d.ts +97 -0
  38. package/dist/pages/SM-8.11/ModelerHomePage.js +956 -0
  39. package/dist/pages/SM-8.11/NavigationPage.d.ts +58 -0
  40. package/dist/pages/SM-8.11/NavigationPage.js +389 -0
  41. package/dist/pages/SM-8.11/OCIdentityAuthorizationsPage.d.ts +10 -0
  42. package/dist/pages/SM-8.11/OCIdentityAuthorizationsPage.js +22 -0
  43. package/dist/pages/SM-8.11/OCIdentityClusterVariablesPage.d.ts +22 -0
  44. package/dist/pages/SM-8.11/OCIdentityClusterVariablesPage.js +120 -0
  45. package/dist/pages/SM-8.11/OCIdentityGroupsPage.d.ts +39 -0
  46. package/dist/pages/SM-8.11/OCIdentityGroupsPage.js +154 -0
  47. package/dist/pages/SM-8.11/OCIdentityHomePage.d.ts +23 -0
  48. package/dist/pages/SM-8.11/OCIdentityHomePage.js +115 -0
  49. package/dist/pages/SM-8.11/OCIdentityMappingRulesPage.d.ts +23 -0
  50. package/dist/pages/SM-8.11/OCIdentityMappingRulesPage.js +116 -0
  51. package/dist/pages/SM-8.11/OCIdentityRolesPage.d.ts +61 -0
  52. package/dist/pages/SM-8.11/OCIdentityRolesPage.js +433 -0
  53. package/dist/pages/SM-8.11/OCTenantPage.d.ts +73 -0
  54. package/dist/pages/SM-8.11/OCTenantPage.js +399 -0
  55. package/dist/pages/SM-8.11/OperateHomePage.d.ts +26 -0
  56. package/dist/pages/SM-8.11/OperateHomePage.js +139 -0
  57. package/dist/pages/SM-8.11/OperateProcessInstancePage.d.ts +30 -0
  58. package/dist/pages/SM-8.11/OperateProcessInstancePage.js +276 -0
  59. package/dist/pages/SM-8.11/OperateProcessesPage.d.ts +38 -0
  60. package/dist/pages/SM-8.11/OperateProcessesPage.js +383 -0
  61. package/dist/pages/SM-8.11/OptimizeCollectionsPage.d.ts +17 -0
  62. package/dist/pages/SM-8.11/OptimizeCollectionsPage.js +62 -0
  63. package/dist/pages/SM-8.11/OptimizeDashboardPage.d.ts +14 -0
  64. package/dist/pages/SM-8.11/OptimizeDashboardPage.js +63 -0
  65. package/dist/pages/SM-8.11/OptimizeHomePage.d.ts +19 -0
  66. package/dist/pages/SM-8.11/OptimizeHomePage.js +76 -0
  67. package/dist/pages/SM-8.11/OptimizeReportPage.d.ts +50 -0
  68. package/dist/pages/SM-8.11/OptimizeReportPage.js +209 -0
  69. package/dist/pages/SM-8.11/PlayPage.d.ts +47 -0
  70. package/dist/pages/SM-8.11/PlayPage.js +389 -0
  71. package/dist/pages/SM-8.11/ProcessApplicationPage.d.ts +35 -0
  72. package/dist/pages/SM-8.11/ProcessApplicationPage.js +340 -0
  73. package/dist/pages/SM-8.11/SettingsPage.d.ts +12 -0
  74. package/dist/pages/SM-8.11/SettingsPage.js +34 -0
  75. package/dist/pages/SM-8.11/TaskDetailsPage.d.ts +70 -0
  76. package/dist/pages/SM-8.11/TaskDetailsPage.js +273 -0
  77. package/dist/pages/SM-8.11/TaskPanelPage.d.ts +29 -0
  78. package/dist/pages/SM-8.11/TaskPanelPage.js +320 -0
  79. package/dist/pages/SM-8.11/TaskProcessesPage.d.ts +15 -0
  80. package/dist/pages/SM-8.11/TaskProcessesPage.js +77 -0
  81. package/dist/pages/SM-8.11/UtilitiesPage.d.ts +38 -0
  82. package/dist/pages/SM-8.11/UtilitiesPage.js +573 -0
  83. package/dist/pages/SM-8.11/optimizeReportUtils.d.ts +6 -0
  84. package/dist/pages/SM-8.11/optimizeReportUtils.js +77 -0
  85. package/dist/tests/SM-8.11/cluster-management-user-flows.spec.d.ts +1 -0
  86. package/dist/tests/SM-8.11/cluster-management-user-flows.spec.js +48 -0
  87. package/dist/tests/SM-8.11/cluster-variables.spec.d.ts +1 -0
  88. package/dist/tests/SM-8.11/cluster-variables.spec.js +226 -0
  89. package/dist/tests/SM-8.11/connectors-user-flows.spec.d.ts +1 -0
  90. package/dist/tests/SM-8.11/connectors-user-flows.spec.js +307 -0
  91. package/dist/tests/SM-8.11/document-handling-user-flows.spec.d.ts +1 -0
  92. package/dist/tests/SM-8.11/document-handling-user-flows.spec.js +174 -0
  93. package/dist/tests/SM-8.11/hto-user-flows.spec.d.ts +1 -0
  94. package/dist/tests/SM-8.11/hto-user-flows.spec.js +410 -0
  95. package/dist/tests/SM-8.11/hub-web-modeler-smoke.spec.d.ts +1 -0
  96. package/dist/tests/SM-8.11/hub-web-modeler-smoke.spec.js +24 -0
  97. package/dist/tests/SM-8.11/identity-user-flows.spec.d.ts +1 -0
  98. package/dist/tests/SM-8.11/identity-user-flows.spec.js +220 -0
  99. package/dist/tests/SM-8.11/license-key-user-flows.spec.d.ts +1 -0
  100. package/dist/tests/SM-8.11/license-key-user-flows.spec.js +461 -0
  101. package/dist/tests/SM-8.11/login.spec.d.ts +1 -0
  102. package/dist/tests/SM-8.11/login.spec.js +24 -0
  103. package/dist/tests/SM-8.11/migration-path-user-flows.spec.d.ts +1 -0
  104. package/dist/tests/SM-8.11/migration-path-user-flows.spec.js +263 -0
  105. package/dist/tests/SM-8.11/mt-enabled-user-flows.spec.d.ts +1 -0
  106. package/dist/tests/SM-8.11/mt-enabled-user-flows.spec.js +607 -0
  107. package/dist/tests/SM-8.11/optimize-user-flows.spec.d.ts +1 -0
  108. package/dist/tests/SM-8.11/optimize-user-flows.spec.js +505 -0
  109. package/dist/tests/SM-8.11/play.spec.d.ts +1 -0
  110. package/dist/tests/SM-8.11/play.spec.js +144 -0
  111. package/dist/tests/SM-8.11/rba-enabled-user-flows.spec.d.ts +1 -0
  112. package/dist/tests/SM-8.11/rba-enabled-user-flows.spec.js +712 -0
  113. package/dist/tests/SM-8.11/smoke-tests.spec.d.ts +1 -0
  114. package/dist/tests/SM-8.11/smoke-tests.spec.js +167 -0
  115. package/dist/tests/SM-8.11/test-setup.spec.d.ts +1 -0
  116. package/dist/tests/SM-8.11/test-setup.spec.js +24 -0
  117. package/dist/tests/SM-8.11/topology-orchestration-smoke.spec.d.ts +1 -0
  118. package/dist/tests/SM-8.11/topology-orchestration-smoke.spec.js +58 -0
  119. package/dist/tests/SM-8.11/web-modeler-user-flows.spec.d.ts +1 -0
  120. package/dist/tests/SM-8.11/web-modeler-user-flows.spec.js +223 -0
  121. package/package.json +1 -1
  122. package/playwright.config.ts +21 -0
@@ -0,0 +1,485 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.IdentityUsersPage = void 0;
4
+ const test_1 = require("@playwright/test");
5
+ const sleep_1 = require("../../utils/sleep");
6
+ class IdentityUsersPage {
7
+ page;
8
+ usersTab;
9
+ optionsButton;
10
+ editUserMenuItem;
11
+ operationsEngineerCheckbox;
12
+ developerCheckbox;
13
+ analystCheckbox;
14
+ confirmButton;
15
+ settingsTab;
16
+ optInButton;
17
+ optInCheckbox;
18
+ newContextPadButton;
19
+ newContextPadButtonText;
20
+ mainUser;
21
+ authorizations;
22
+ noAuthorizedResourceMessage;
23
+ dialog;
24
+ deleteAuthorisedResourceButton;
25
+ deleteAuthorisedResourceSubButton;
26
+ createResourceAuthorizationButton;
27
+ createResourceAuthorizationDialog;
28
+ nextButton;
29
+ createButton;
30
+ idComboBox;
31
+ readPermissionCheckbox;
32
+ startProcessIPermissionCheckbox;
33
+ optInAICheckbox;
34
+ rows;
35
+ groupsTab;
36
+ createGroupButton;
37
+ createGroupSubButton;
38
+ groupNameInput;
39
+ noGroupsHeading;
40
+ createFirstGroupButton;
41
+ createGroupDialoge;
42
+ assignMembersButton;
43
+ assignMembersSubButton;
44
+ assignMembersSearchbox;
45
+ assignMembersSearchResult;
46
+ organizationManagementLink;
47
+ deleteSubButton;
48
+ deleteButton;
49
+ filterTableSearchbox;
50
+ assignAuthorizationButton;
51
+ assignedRolesTab;
52
+ constructor(page) {
53
+ this.page = page;
54
+ this.usersTab = page.getByRole('tab', { name: 'Users' });
55
+ this.optionsButton = page.getByRole('button', { name: 'Options' });
56
+ this.editUserMenuItem = page.getByRole('menuitem', { name: 'Edit User' });
57
+ this.operationsEngineerCheckbox = page
58
+ .getByRole('group')
59
+ .locator('label')
60
+ .filter({ hasText: 'Operations Engineer' });
61
+ this.developerCheckbox = page
62
+ .getByRole('group')
63
+ .locator('label')
64
+ .filter({ hasText: 'Developer' });
65
+ this.analystCheckbox = page
66
+ .getByRole('group')
67
+ .locator('label')
68
+ .filter({ hasText: 'Analyst' });
69
+ this.confirmButton = page.getByRole('button', { name: 'Confirm' });
70
+ this.settingsTab = page.getByRole('tab', { name: 'Settings' });
71
+ this.optInButton = page.getByRole('button', { name: 'Opt-in', exact: true });
72
+ this.optInCheckbox = page.getByLabel('I understand and agree to the');
73
+ this.newContextPadButton = page.getByRole('switch').last();
74
+ this.newContextPadButtonText = page
75
+ .locator('[class= "cds--toggle__text"]')
76
+ .last();
77
+ this.mainUser = page
78
+ .getByRole('row')
79
+ .filter({ hasText: process.env.C8_USERNAME });
80
+ this.authorizations = page.getByRole('tab', {
81
+ name: 'Authorizations',
82
+ });
83
+ this.noAuthorizedResourceMessage = page.getByText("You haven't created any resource authorizations yet", { exact: true });
84
+ this.dialog = page.getByRole('dialog');
85
+ this.deleteAuthorisedResourceButton = page.getByRole('button', {
86
+ name: 'Delete',
87
+ });
88
+ this.deleteAuthorisedResourceSubButton = page.getByRole('button', {
89
+ name: 'danger Delete',
90
+ });
91
+ this.createResourceAuthorizationButton = page.getByRole('button', {
92
+ name: 'Create resource authorization',
93
+ exact: true,
94
+ });
95
+ this.createResourceAuthorizationDialog = page.getByRole('dialog', {
96
+ name: 'Create resource authorizations',
97
+ exact: true,
98
+ });
99
+ this.nextButton = this.createResourceAuthorizationDialog.getByRole('button', {
100
+ name: 'Next',
101
+ });
102
+ this.createButton = this.createResourceAuthorizationDialog.getByRole('button', {
103
+ name: 'Create',
104
+ });
105
+ this.idComboBox = page.getByRole('combobox', { name: 'ID' });
106
+ this.readPermissionCheckbox = page
107
+ .locator('label')
108
+ .filter({ hasText: 'ReadRead-only access to' });
109
+ this.startProcessIPermissionCheckbox = page.getByRole('checkbox', {
110
+ name: 'Start process instance',
111
+ });
112
+ this.optInAICheckbox = page.getByLabel('I understand and agree to Terms for AI Usage');
113
+ this.rows = this.page.getByRole('row');
114
+ this.groupsTab = page.getByRole('tab', { name: 'Groups' });
115
+ this.createGroupButton = page.getByRole('button', {
116
+ name: 'create group',
117
+ });
118
+ this.createGroupSubButton = page
119
+ .getByRole('button', {
120
+ name: 'create group',
121
+ })
122
+ .last();
123
+ this.groupNameInput = page.getByRole('textbox', { name: 'name' });
124
+ this.noGroupsHeading = page.getByRole('heading', {
125
+ name: 'you don’t have any groups yet',
126
+ });
127
+ this.createFirstGroupButton = page.getByRole('button', {
128
+ name: 'create a group',
129
+ });
130
+ this.createGroupDialoge = page.getByRole('dialog', {
131
+ name: 'create group',
132
+ });
133
+ this.assignMembersButton = page.getByRole('button', {
134
+ name: 'assign members',
135
+ });
136
+ this.assignMembersSubButton = page
137
+ .getByRole('button', {
138
+ name: 'assign',
139
+ })
140
+ .last();
141
+ this.assignMembersSearchbox = page.getByRole('searchbox', {
142
+ name: 'search by full name or email address',
143
+ });
144
+ this.assignMembersSearchResult = page.locator('.cds--list-box__menu-item');
145
+ this.organizationManagementLink = page.getByRole('link', {
146
+ name: 'organization management',
147
+ });
148
+ this.deleteButton = page.getByRole('button', { name: 'delete' });
149
+ this.deleteSubButton = page
150
+ .getByRole('button', {
151
+ name: 'danger',
152
+ })
153
+ .last();
154
+ this.filterTableSearchbox = page.getByRole('searchbox', {
155
+ name: 'Filter table',
156
+ });
157
+ this.assignAuthorizationButton = page.getByRole('button', {
158
+ name: 'Assign authorization',
159
+ exact: true,
160
+ });
161
+ this.assignedRolesTab = page.getByRole('tab', { name: 'Assigned roles' });
162
+ }
163
+ async clickCreateAuthorizedResourceButton() {
164
+ await (0, test_1.expect)(this.createButton).toBeVisible({ timeout: 60000 });
165
+ await this.createButton.click();
166
+ }
167
+ async processIdResourceAssertion(processId) {
168
+ await (0, test_1.expect)(this.page.getByRole('row', { name: processId })).toBeVisible({
169
+ timeout: 90000,
170
+ });
171
+ }
172
+ async clickCreateResourceAuthorizationButton() {
173
+ await (0, test_1.expect)(this.createResourceAuthorizationButton).toBeVisible({
174
+ timeout: 60000,
175
+ });
176
+ await this.createResourceAuthorizationButton.click();
177
+ }
178
+ async clickNextButton() {
179
+ await (0, test_1.expect)(this.nextButton).toBeVisible({
180
+ timeout: 60000,
181
+ });
182
+ await this.nextButton.click();
183
+ }
184
+ async clickProcessIdInput() {
185
+ await (0, test_1.expect)(this.idComboBox).toBeVisible({ timeout: 60000 });
186
+ await this.idComboBox.click();
187
+ }
188
+ async fillProcessIdInput(processId) {
189
+ await this.idComboBox.fill(processId);
190
+ }
191
+ async checkReadPermissionCheckbox() {
192
+ await (0, test_1.expect)(this.readPermissionCheckbox).toBeVisible({ timeout: 60000 });
193
+ if (!(await this.readPermissionCheckbox.isChecked())) {
194
+ await this.readPermissionCheckbox.click({ force: true });
195
+ }
196
+ }
197
+ async checkStartInstancePermissionCheckbox() {
198
+ if (!(await this.startProcessIPermissionCheckbox.isChecked())) {
199
+ await this.startProcessIPermissionCheckbox.click({ force: true });
200
+ }
201
+ }
202
+ async clickUsersTab() {
203
+ await this.usersTab.click({ timeout: 60000 });
204
+ }
205
+ async clickOptionsButton() {
206
+ await this.optionsButton.click({ timeout: 90000 });
207
+ }
208
+ async clickEditUserMenuItem() {
209
+ await this.editUserMenuItem.click({ timeout: 60000 });
210
+ }
211
+ async clickOperationsEngineerCheckbox() {
212
+ await this.operationsEngineerCheckbox.click();
213
+ }
214
+ async checkDeveloperCheckbox() {
215
+ if (!(await this.developerCheckbox.isChecked())) {
216
+ await this.developerCheckbox.click({ timeout: 60000 });
217
+ }
218
+ }
219
+ async uncheckDeveloperCheckbox() {
220
+ if (await this.developerCheckbox.isChecked()) {
221
+ await this.developerCheckbox.click({ timeout: 60000 });
222
+ }
223
+ }
224
+ async checkAnalystCheckbox() {
225
+ if (!(await this.analystCheckbox.isChecked())) {
226
+ await this.analystCheckbox.click({ timeout: 60000 });
227
+ }
228
+ }
229
+ async uncheckAnalystCheckbox() {
230
+ if (await this.analystCheckbox.isChecked()) {
231
+ await this.analystCheckbox.click({ timeout: 60000 });
232
+ }
233
+ }
234
+ async clickConfirmButton() {
235
+ await this.confirmButton.click({ timeout: 60000 });
236
+ }
237
+ async clickSettingsTab() {
238
+ await this.settingsTab.click({ timeout: 120000 });
239
+ try {
240
+ await (0, test_1.expect)(this.page.getByRole('heading', { name: 'Alpha features' })).toBeVisible({
241
+ timeout: 120000,
242
+ });
243
+ }
244
+ catch (error) {
245
+ await this.settingsTab.click({ timeout: 120000 });
246
+ }
247
+ }
248
+ async clickOptInButton() {
249
+ await this.optInButton.click({ timeout: 60000 });
250
+ }
251
+ async enableAlphaFeature(name) {
252
+ await (0, test_1.expect)(this.rows.first()).toBeVisible({ timeout: 10000 });
253
+ const alphaFeature = this.rows.filter({ hasText: name }).first();
254
+ if ((await alphaFeature.count()) < 1) {
255
+ console.error(`No alpha feature(${name}) is found.`);
256
+ return;
257
+ }
258
+ //Opt-in The Alpha Feature
259
+ const alphaFeatureOptInButton = alphaFeature.getByRole('button', {
260
+ name: 'Opt-in to enable',
261
+ });
262
+ if (await alphaFeatureOptInButton.isVisible({ timeout: 10000 })) {
263
+ await alphaFeatureOptInButton.click();
264
+ await this.optInAICheckbox.scrollIntoViewIfNeeded();
265
+ await this.optInAICheckbox.check({ timeout: 90000 });
266
+ await (0, sleep_1.sleep)(3000);
267
+ }
268
+ //Enable Alpha Feature
269
+ const toggleText = await alphaFeature
270
+ .locator('[class= "cds--toggle__text"]')
271
+ .textContent();
272
+ console.info(`Previous feature(${name}) setting is ${toggleText}.`);
273
+ if (toggleText == 'Enabled') {
274
+ console.log(`Feature ${name} is already enabled.`);
275
+ return;
276
+ }
277
+ if (toggleText == 'Disabled') {
278
+ await alphaFeature
279
+ .locator('[class= "cds--toggle__switch"]')
280
+ .first()
281
+ .click();
282
+ await (0, sleep_1.sleep)(10000);
283
+ }
284
+ await (0, test_1.expect)(alphaFeature.locator('[class= "cds--toggle__text"]')).toHaveText('Enabled');
285
+ }
286
+ async scrollToOptInCheckbox() {
287
+ await this.page
288
+ .getByText('Access and Use of the Camunda')
289
+ .scrollIntoViewIfNeeded();
290
+ await this.page
291
+ .getByText('Pre-release. The Customer')
292
+ .scrollIntoViewIfNeeded();
293
+ await this.page
294
+ .getByText('Confidential Information. The')
295
+ .scrollIntoViewIfNeeded();
296
+ await this.page
297
+ .getByText('THESE TERMS DO NOT ENTITLE')
298
+ .scrollIntoViewIfNeeded();
299
+ await this.page
300
+ .getByText('Rights and Obligations Upon')
301
+ .scrollIntoViewIfNeeded();
302
+ await this.page
303
+ .getByText('NOTWITHSTANDING ANYTHING TO')
304
+ .scrollIntoViewIfNeeded();
305
+ await this.page
306
+ .getByRole('heading', { name: 'General' })
307
+ .scrollIntoViewIfNeeded();
308
+ await this.page
309
+ .getByText('Liability. Camunda is liable')
310
+ .scrollIntoViewIfNeeded();
311
+ await this.page
312
+ .getByLabel('I understand and agree to the')
313
+ .scrollIntoViewIfNeeded();
314
+ }
315
+ async checkOptInCheckbox() {
316
+ await this.optInCheckbox.check({ timeout: 90000 });
317
+ }
318
+ async clickMainUser() {
319
+ await (0, test_1.expect)(this.mainUser).toBeVisible({ timeout: 60000 });
320
+ await this.mainUser.click();
321
+ }
322
+ async clickAuthorizations() {
323
+ await (0, test_1.expect)(this.authorizations).toBeVisible({ timeout: 60000 });
324
+ await this.authorizations.click();
325
+ }
326
+ async authorizedResourceAssertion(processId, maxRetries = 3, timeout = 30000) {
327
+ for (let attempt = 0; attempt < maxRetries; attempt++) {
328
+ try {
329
+ await this.page.reload();
330
+ await this.clickAuthorizations();
331
+ await (0, test_1.expect)(this.page.getByRole('row', { name: processId })).toBeVisible({ timeout: timeout });
332
+ return;
333
+ }
334
+ catch (error) {
335
+ if (attempt < maxRetries - 1) {
336
+ console.warn(`Attempt ${attempt + 1} failed. Retrying...`);
337
+ }
338
+ else {
339
+ throw new Error(`Assertion failed after ${maxRetries} attempts`);
340
+ }
341
+ }
342
+ }
343
+ }
344
+ async clickNewContextPadButton() {
345
+ try {
346
+ await (0, test_1.expect)(this.newContextPadButtonText).toHaveText('Enabled', {
347
+ timeout: 90000,
348
+ });
349
+ }
350
+ catch {
351
+ await this.page.reload();
352
+ await this.newContextPadButton.click({ timeout: 90000 });
353
+ await (0, test_1.expect)(this.newContextPadButtonText).toHaveText('Enabled', {
354
+ timeout: 60000,
355
+ });
356
+ }
357
+ }
358
+ async optInToAlphaFeatures() {
359
+ try {
360
+ await (0, test_1.expect)(this.optInButton).toBeVisible({ timeout: 30000 });
361
+ await this.clickOptInButton();
362
+ await this.scrollToOptInCheckbox();
363
+ await this.checkOptInCheckbox();
364
+ }
365
+ catch {
366
+ await (0, test_1.expect)(this.optInButton).not.toBeVisible();
367
+ }
368
+ }
369
+ async clickGroupsTab() {
370
+ await this.groupsTab.click({ timeout: 60000 });
371
+ }
372
+ async clickCreateGroupButton() {
373
+ const maxRetries = 3;
374
+ for (let retries = 0; retries < maxRetries; retries++) {
375
+ try {
376
+ if (!(await this.noGroupsHeading.isVisible({ timeout: 120000 }))) {
377
+ await this.createGroupButton.click();
378
+ }
379
+ else {
380
+ await this.createFirstGroupButton.click();
381
+ }
382
+ return;
383
+ }
384
+ catch (error) {
385
+ console.error(`Click attempt ${retries + 1} failed`);
386
+ }
387
+ }
388
+ throw new Error(`Failed to click the button after ${maxRetries} attempts.`);
389
+ }
390
+ async fillGroupNameInput(name) {
391
+ await this.groupNameInput.fill(name);
392
+ }
393
+ async clickCreateGroupSubButton() {
394
+ await this.createGroupSubButton.click();
395
+ }
396
+ async clickUserGroup(name) {
397
+ await this.page.getByRole('cell', { name: name }).click();
398
+ }
399
+ async clickAssignMembers() {
400
+ await this.assignMembersButton.click();
401
+ }
402
+ async fillAssignMembers(names) {
403
+ for (const name of names) {
404
+ await this.assignMembersSearchbox.click({ timeout: 60000 });
405
+ await this.assignMembersSearchbox.fill(name);
406
+ await this.assignMembersSearchResult
407
+ .filter({ hasText: name })
408
+ .click({ timeout: 120000 });
409
+ }
410
+ }
411
+ async filterTable(names) {
412
+ for (const name of names) {
413
+ await this.filterTableSearchbox.click({ timeout: 60000 });
414
+ await this.filterTableSearchbox.fill(name);
415
+ }
416
+ }
417
+ async clickAssignSubButton() {
418
+ await this.assignMembersSubButton.click();
419
+ }
420
+ async clickOrganizationManagementLink() {
421
+ await this.organizationManagementLink.click();
422
+ }
423
+ async deleteAllGroups() {
424
+ try {
425
+ await this.deleteButton
426
+ .first()
427
+ .waitFor({ state: 'visible', timeout: 60000 });
428
+ const count = await this.deleteButton.count();
429
+ if (count > 0) {
430
+ for (let i = 0; i < count; i++) {
431
+ await this.deleteButton.nth(i).click({ timeout: 60000 });
432
+ await this.deleteSubButton.click({ timeout: 60000 });
433
+ }
434
+ }
435
+ }
436
+ catch (error) {
437
+ console.log('Delete Button Not Clicked ' + error);
438
+ }
439
+ }
440
+ async createResourceAuthorization(processId) {
441
+ try {
442
+ await this.clickCreateResourceAuthorizationButton();
443
+ }
444
+ catch {
445
+ await this.clickAssignAuthorizationButton();
446
+ }
447
+ await (0, test_1.expect)(this.createResourceAuthorizationDialog).toBeVisible({
448
+ timeout: 60000,
449
+ });
450
+ await this.clickNextButton();
451
+ await this.clickProcessIdInput();
452
+ await this.fillProcessIdInput(processId);
453
+ await this.clickNextButton();
454
+ await this.checkReadPermissionCheckbox();
455
+ await this.checkStartInstancePermissionCheckbox();
456
+ await this.clickCreateAuthorizedResourceButton();
457
+ await this.processIdResourceAssertion(processId);
458
+ }
459
+ async clickAssignAuthorizationButton() {
460
+ await this.assignAuthorizationButton.click();
461
+ }
462
+ async clickAssignedRolesTab() {
463
+ await this.assignedRolesTab.click();
464
+ }
465
+ // A role entry may be a single name, or a list of interchangeable names when
466
+ // Management Identity ships the same permission set under more than one label
467
+ // (e.g. 'Hub'/'Web Modeler'); any one of the listed names satisfies the entry.
468
+ async assertUserIsAssignedCorrectRole(username, roles) {
469
+ await this.page.getByRole('cell', { name: username, exact: true }).click();
470
+ // Wait for the Assigned Roles tab to render before clicking it; after
471
+ // navigating to a user row the panel can take a moment to hydrate.
472
+ await (0, test_1.expect)(this.assignedRolesTab).toBeVisible({ timeout: 30000 });
473
+ await this.assignedRolesTab.click();
474
+ for (const role of roles) {
475
+ const acceptedNames = Array.isArray(role) ? role : [role];
476
+ const roleCell = acceptedNames
477
+ .map((name) => this.page.getByRole('cell', { name, exact: true }))
478
+ .reduce((combined, cell) => combined.or(cell));
479
+ // Use a generous timeout: on slow/post-upgrade clusters the role table
480
+ // may take several seconds to populate after the tab switch.
481
+ await (0, test_1.expect)(roleCell.first()).toBeVisible({ timeout: 60000 });
482
+ }
483
+ }
484
+ }
485
+ exports.IdentityUsersPage = IdentityUsersPage;
@@ -0,0 +1,17 @@
1
+ import { Page, Locator } from '@playwright/test';
2
+ declare class KeycloakAdminPage {
3
+ private page;
4
+ readonly keycloakBanner: Locator;
5
+ readonly addUserButton: Locator;
6
+ readonly credentialsTab: Locator;
7
+ constructor(page: Page);
8
+ toBeVisible(): Promise<void>;
9
+ switchToCamundaPlatform(): Promise<void>;
10
+ clickUsersTab(): Promise<void>;
11
+ clickAddUser(): Promise<void>;
12
+ fillUser(username: string): Promise<void>;
13
+ saveUser(): Promise<void>;
14
+ fillPassword(password: string): Promise<void>;
15
+ savePassword(): Promise<void>;
16
+ }
17
+ export { KeycloakAdminPage };
@@ -0,0 +1,78 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.KeycloakAdminPage = void 0;
4
+ const test_1 = require("@playwright/test");
5
+ const sleep_1 = require("../../utils/sleep");
6
+ class KeycloakAdminPage {
7
+ page;
8
+ keycloakBanner;
9
+ addUserButton;
10
+ credentialsTab;
11
+ constructor(page) {
12
+ this.page = page;
13
+ this.keycloakBanner = page.locator('#kc-main-content-page-container');
14
+ this.addUserButton = page.getByTestId('add-user');
15
+ this.credentialsTab = page.getByTestId('credentials');
16
+ }
17
+ async toBeVisible() {
18
+ await (0, test_1.expect)(this.keycloakBanner).toBeVisible({ timeout: 60000 });
19
+ }
20
+ async switchToCamundaPlatform() {
21
+ const realmSelector = this.page.getByTestId('nav-item-realms');
22
+ await realmSelector.click();
23
+ const searchField = this.page.getByTestId('selectRealminput');
24
+ await searchField.click();
25
+ await this.page
26
+ .getByPlaceholder('Search')
27
+ .fill(process.env.KEYCLOAK_REALM || 'camunda-platform');
28
+ await this.page
29
+ .locator('[data-ouia-component-id="OUIA-Generated-Button-control-1"]')
30
+ .click();
31
+ // The realm search result renders after an async lookup, so a bare click
32
+ // races Playwright's default 10s action timeout — wait for it explicitly
33
+ // (matching clickAddUser/fillPassword's 30s waits elsewhere in this file)
34
+ // instead of relying on the click's own implicit wait.
35
+ const realmResult = this.page.getByText(process.env.KEYCLOAK_REALM || 'camunda-platform');
36
+ await (0, test_1.expect)(realmResult).toBeVisible({ timeout: 30000 });
37
+ await realmResult.click();
38
+ const mainLocator = this.page.locator('#kc-main-content-page-container');
39
+ await (0, test_1.expect)(mainLocator).toBeVisible({ timeout: 60000 });
40
+ }
41
+ async clickUsersTab() {
42
+ await this.page.click('a[id="nav-item-users"]');
43
+ }
44
+ async clickAddUser() {
45
+ await (0, test_1.expect)(this.addUserButton).toBeVisible({ timeout: 30000 });
46
+ await this.addUserButton.click();
47
+ }
48
+ async fillUser(username) {
49
+ await this.page.getByTestId('username').fill(username);
50
+ await this.page.getByTestId('firstName').fill(`test${username}`);
51
+ await this.page.getByTestId('lastName').fill('user');
52
+ await this.page
53
+ .getByTestId('email')
54
+ .fill(`qacamunda+${username}@gmail.com`);
55
+ }
56
+ async saveUser() {
57
+ await this.page.getByTestId('user-creation-save').click();
58
+ }
59
+ async fillPassword(password) {
60
+ await (0, test_1.expect)(this.credentialsTab).toBeVisible({ timeout: 30000 });
61
+ await this.credentialsTab.click();
62
+ await this.page.getByTestId('no-credentials-empty-action').click();
63
+ await this.page.getByTestId('passwordField').fill(password);
64
+ await this.page.getByTestId('passwordConfirmationField').fill(password);
65
+ }
66
+ async savePassword() {
67
+ await this.page
68
+ .locator('label.pf-v5-c-switch[for="temporaryPassword"]')
69
+ .click();
70
+ await this.page.getByTestId('confirm').click();
71
+ await this.page.getByTestId('confirm').click();
72
+ // if the browser is firefox, delay for 500 ms
73
+ if (await this.page.evaluate(() => navigator.userAgent.includes('Firefox'))) {
74
+ await (0, sleep_1.sleep)(500);
75
+ }
76
+ }
77
+ }
78
+ exports.KeycloakAdminPage = KeycloakAdminPage;
@@ -0,0 +1,12 @@
1
+ import { Locator, Page } from '@playwright/test';
2
+ declare class KeycloakLoginPage {
3
+ private page;
4
+ readonly keycloakBanner: Locator;
5
+ constructor(page: Page);
6
+ toBeVisible(): Promise<void>;
7
+ fillUsername(username: string): Promise<void>;
8
+ fillPassword(password: string): Promise<void>;
9
+ clearSession(): Promise<void>;
10
+ clickLogin(): Promise<void>;
11
+ }
12
+ export { KeycloakLoginPage };
@@ -0,0 +1,32 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.KeycloakLoginPage = void 0;
4
+ const test_1 = require("@playwright/test");
5
+ class KeycloakLoginPage {
6
+ page;
7
+ keycloakBanner;
8
+ constructor(page) {
9
+ this.page = page;
10
+ this.keycloakBanner = page.locator('#keycloak-bg');
11
+ }
12
+ async toBeVisible() {
13
+ await (0, test_1.expect)(this.keycloakBanner).toBeVisible();
14
+ }
15
+ async fillUsername(username) {
16
+ await this.page.fill('#username', username);
17
+ }
18
+ async fillPassword(password) {
19
+ await this.page.fill('#password', password);
20
+ }
21
+ async clearSession() {
22
+ await this.page.context().clearCookies();
23
+ }
24
+ async clickLogin() {
25
+ // Submitting the Keycloak form starts a redirect chain that page.click
26
+ // implicitly waits on ("waiting for scheduled navigations to finish"), so
27
+ // the action inherits the 10s actionTimeout to cover a navigation. Give it
28
+ // the navigation budget the rest of the suite uses instead.
29
+ await this.page.click('button[type="submit"]', { timeout: 60000 });
30
+ }
31
+ }
32
+ exports.KeycloakLoginPage = KeycloakLoginPage;
@@ -0,0 +1,17 @@
1
+ import { NavigationPage } from '../SM-8.11/NavigationPage';
2
+ import { ManagementIdentityPage } from '../SM-8.11/ManagementIdentityPage';
3
+ import { KeycloakLoginPage } from '../SM-8.11/KeycloakLoginPage';
4
+ import { KeycloakAdminPage } from '../SM-8.11/KeycloakAdminPage';
5
+ import { OCIdentityHomePage } from './OCIdentityHomePage';
6
+ import { OCIdentityRolesPage } from './OCIdentityRolesPage';
7
+ import { IdentityTenantPage } from './IdentityTenantPage';
8
+ export declare const keycloakAdminCredentials: () => {
9
+ username: string;
10
+ password: string;
11
+ };
12
+ export declare const setupKeycloakUser: (navigationPage: NavigationPage, identityPage: ManagementIdentityPage, keycloakLoginPage: KeycloakLoginPage, keycloakAdminPage: KeycloakAdminPage, ocIdentityHomePage: OCIdentityHomePage, ocIdentityRolesPage: OCIdentityRolesPage, assignToDefaultTenant?: boolean, managementIdentityTenantPage?: IdentityTenantPage) => Promise<{
13
+ testUsername: string;
14
+ testPassword: string;
15
+ }>;
16
+ export declare function createUser(navigationPage: NavigationPage, identityPage: ManagementIdentityPage, keycloakLoginPage: KeycloakLoginPage, keycloakAdminPage: KeycloakAdminPage, username: string, password: string): Promise<void>;
17
+ export declare function createKeycloakUser(navigationPage: NavigationPage, keycloakLoginPage: KeycloakLoginPage, keycloakAdminPage: KeycloakAdminPage, username: string, password: string): Promise<void>;