@camunda/e2e-test-suite 0.0.1082 → 0.0.1083
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.
|
@@ -70,9 +70,15 @@ class OCTenantPage {
|
|
|
70
70
|
.getByRole('button', { name: 'Close' });
|
|
71
71
|
this.rolesTab = page.getByRole('tab', { name: 'Roles' });
|
|
72
72
|
this.assignRoleButton = page.getByRole('button', { name: 'Assign role' });
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
73
|
+
// The design-system Admin shell renders the Assign role modal's search
|
|
74
|
+
// field as a cmdk command input (role="combobox", type="text"), so the
|
|
75
|
+
// Carbon searchbox role no longer resolves - match the new field by its
|
|
76
|
+
// placeholder and keep the legacy role match as a fallback, the same
|
|
77
|
+
// dual-shell pattern the table filter locator below uses.
|
|
78
|
+
this.roleIdSearchBox = page
|
|
79
|
+
.getByPlaceholder('Search by role ID')
|
|
80
|
+
.or(page.getByRole('searchbox', { name: 'Search by Role ID' }))
|
|
81
|
+
.first();
|
|
76
82
|
this.assignRoleModal = page.getByLabel('Assign role');
|
|
77
83
|
this.assignRoleSubButton = this.assignRoleModal.getByRole('button', {
|
|
78
84
|
name: 'Assign role',
|
|
@@ -267,13 +273,20 @@ class OCTenantPage {
|
|
|
267
273
|
await this.assignRoleButton.click();
|
|
268
274
|
}
|
|
269
275
|
async clickRoleIdSearchBox() {
|
|
270
|
-
await this.roleIdSearchBox.click();
|
|
276
|
+
await this.roleIdSearchBox.click({ timeout: 60000 });
|
|
271
277
|
}
|
|
272
278
|
async fillRoleIdSearchBox(roleId, roleIdentifier) {
|
|
273
|
-
//
|
|
274
|
-
//
|
|
275
|
-
//
|
|
276
|
-
|
|
279
|
+
// The design-system shell portals the matches into a listbox rendered as
|
|
280
|
+
// a sibling of the dialog, so they cannot be scoped to the modal. The
|
|
281
|
+
// legacy Carbon list stays inside it and must remain scoped: the tenant's
|
|
282
|
+
// own roles table sits behind the modal and carries the same role text, so
|
|
283
|
+
// an unscoped match resolves to that row and its click is intercepted by
|
|
284
|
+
// the modal overlay.
|
|
285
|
+
const result = this.page
|
|
286
|
+
.getByRole('option')
|
|
287
|
+
.filter({ hasText: roleIdentifier })
|
|
288
|
+
.or(this.assignRoleModal.getByText(roleIdentifier))
|
|
289
|
+
.first();
|
|
277
290
|
// The dropdown matches against the roles fetched with an empty search
|
|
278
291
|
// filter, so clearing the box re-triggers that fetch before retyping.
|
|
279
292
|
await (0, test_1.expect)(async () => {
|
|
@@ -62,13 +62,16 @@ class PlayPage {
|
|
|
62
62
|
})
|
|
63
63
|
.getByRole('button', { name: 'Delete', exact: true });
|
|
64
64
|
// After saving a scenario, the Scenarios panel is in detail-view mode.
|
|
65
|
-
// To get back to the list (where "Run all
|
|
66
|
-
//
|
|
67
|
-
//
|
|
65
|
+
// To get back to the list (where "Run all test cases" lives in
|
|
66
|
+
// TestCaseTopBar), click the ghost button at the top of the detail
|
|
67
|
+
// panel — see TestCaseDetail.tsx Header.
|
|
68
68
|
// This replaces the legacy bottom-bar `(View all)` link that used to
|
|
69
69
|
// close the saved-scenario view.
|
|
70
|
+
// camunda-hub cfaea03 (#28259, "rename play package to test-studio")
|
|
71
|
+
// relabelled it "Back to all test cases"; the anchored regex below must
|
|
72
|
+
// keep the optional "all " or it matches nothing on current builds.
|
|
70
73
|
this.viewAllScenariosButton = page.getByRole('button', {
|
|
71
|
-
name: /^Back to (scenarios|test cases)$/i,
|
|
74
|
+
name: /^Back to (all )?(scenarios|test cases)$/i,
|
|
72
75
|
});
|
|
73
76
|
this.getScenarioRowByName = (scenarioName) => page.locator('tr', { hasText: scenarioName });
|
|
74
77
|
this.getScenarioRow = (scenarioName) => page.locator('tr', { hasText: scenarioName });
|
|
@@ -128,14 +131,19 @@ class PlayPage {
|
|
|
128
131
|
name: /^(Scenarios|Test cases)$/i,
|
|
129
132
|
});
|
|
130
133
|
const backToScenariosButton = scenariosRegion.getByRole('button', {
|
|
131
|
-
name: /^Back to (scenarios|test cases)$/i,
|
|
134
|
+
name: /^Back to (all )?(scenarios|test cases)$/i,
|
|
132
135
|
});
|
|
133
|
-
|
|
136
|
+
// TestPanel.tsx labels this `Close ${title} panel`, so match on the
|
|
137
|
+
// substring rather than the exact accessible name.
|
|
138
|
+
const closeScenariosButton = scenariosRegion
|
|
139
|
+
.getByRole('button', {
|
|
134
140
|
name: 'Close',
|
|
135
|
-
})
|
|
136
|
-
|
|
137
|
-
//
|
|
138
|
-
// the
|
|
141
|
+
})
|
|
142
|
+
.first();
|
|
143
|
+
// When "Configure test case" is clicked with a prior test case already
|
|
144
|
+
// saved, the Test Studio UI opens test-case DETAILS (with "Back to all test
|
|
145
|
+
// cases") instead of the input panel. Close the Test cases panel to reveal
|
|
146
|
+
// the canvas start controls.
|
|
139
147
|
const isDetailsView = await backToScenariosButton
|
|
140
148
|
.waitFor({ state: 'visible', timeout: 3000 })
|
|
141
149
|
.then(() => true)
|
|
@@ -245,8 +253,8 @@ class PlayPage {
|
|
|
245
253
|
}
|
|
246
254
|
async clickViewAllScenariosButton() {
|
|
247
255
|
// This method's job is to reach the scenario LIST. Saving can already leave
|
|
248
|
-
// Play there (see assertSavedScenarioNameInPanel), and the "Back to
|
|
249
|
-
// cases" control exists only inside a scenario's detail view -- so on the
|
|
256
|
+
// Play there (see assertSavedScenarioNameInPanel), and the "Back to all
|
|
257
|
+
// test cases" control exists only inside a scenario's detail view -- so on the
|
|
250
258
|
// list it never renders and waiting for it just burns the retry budget.
|
|
251
259
|
// "Run all test cases" lives on the list and is what the caller needs next,
|
|
252
260
|
// so treat it as proof the destination is already reached.
|