@ironsource/shared-ui-e2e 2.1.11-rc.6 → 2.1.11-rc.60
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.
- package/package.json +1 -1
- package/shared-e2e-commands.js +373 -258
- package/shared-e2e-commands.umd.cjs +1 -1
- package/tests/components/inputs/input-v4/inputs-component.d.ts +5 -2
- package/tests/components/inputs/input-v4/inputs-page.d.ts +2 -0
- package/tests/components/sortablelist/consts.d.ts +5 -0
- package/tests/components/sortablelist/sortable-list-component.d.ts +15 -0
- package/tests/components/sortablelist/sortable-list-page.d.ts +14 -0
- package/tests/components/sortablelist/types.d.ts +28 -0
- package/tests/testids/index.d.ts +2 -0
- package/tsconfig.tsbuildinfo +1 -1
package/shared-e2e-commands.js
CHANGED
|
@@ -1,44 +1,44 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var
|
|
4
|
-
var
|
|
5
|
-
const
|
|
1
|
+
var v = Object.defineProperty;
|
|
2
|
+
var W = (a, t, e) => t in a ? v(a, t, { enumerable: !0, configurable: !0, writable: !0, value: e }) : a[t] = e;
|
|
3
|
+
var c = (a, t, e) => (W(a, typeof t != "symbol" ? t + "" : t, e), e);
|
|
4
|
+
var g = /* @__PURE__ */ ((a) => (a.TRIGGER = "ie-trigger", a.CONTENT = "ie-content", a.SEARCH = "ie-search", a.LIST = "ie-list", a.LIST_SELECTED = "ie-list-selected", a.ACTION_CANCEL = "ie-action-cancel", a.ACTION_APPLY = "ie-action-apply", a.SELECT_ALL = "ie-select-all", a.CLEAR_ALL = "ie-clear-all", a))(g || {}), s = /* @__PURE__ */ ((a) => (a.TRIGGER = "dd-trigger", a.WRAPPER = "dd-wrapper", a.BUTTON = "dd-button", a.BUTTON_WRAPPER = "dd-button-wrapper", a.BUTTON_CONTENT = "dd-button-content", a.BUTTON_CONTENT_SUFFIX = "dd-button-content-suffix", a.BUTTON_CLEAR = "dd-button-clear", a.LABEL = "dd-label", a.LIST_CONTAINER = "dd-list-container", a.SEARCH = "dd-search", a.TITLE = "dd-title", a.ACTION_CANCEL = "dd-action-cancel", a.ACTION_APPLY = "dd-action-apply", a.ACTION_CLEAR_ALL = "dd-action-clear-all", a.HELPER_TEXT = "dd-helper-text", a.HELPER_TEXT_ERROR = "dd-helper-text-error", a.SELECT_ALL = "dd-select-all", a.NO_RESULT = "dd-no-result", a))(s || {}), R = /* @__PURE__ */ ((a) => (a.WRAPPER = "banner-wrapper", a.CONTENT = "banner-content", a))(R || {}), d = /* @__PURE__ */ ((a) => (a.WRAPPER = "alert-wrapper", a.TITLE = "alert-title", a.MESSAGE = "alert-message", a.ACTION_BUTTON = "alert-action-button", a.CLOSE_BUTTON = "alert-close-button", a))(d || {}), u = /* @__PURE__ */ ((a) => (a.WRAPPER = "dialog-wrapper", a.HEADER = "dialog-header", a.ACTION_CLOSE = "dialog-action-close", a.HEADER_SECONDARY = "dialog-header-secondary", a.CONTENT = "dialog-content", a.ACTION_BUTTONS_WRAPPER = "dialog-action-buttons-wrapper", a.BACKDROP = "dialog-backdrop", a.SAVE_BUTTON = "dialog-save-button", a.CANCEL_BUTTON = "dialog-cancel-button", a))(u || {}), r = /* @__PURE__ */ ((a) => (a.WRAPPER = "input-wrapper", a.TOOLTIP = "input-tooltip", a.TOOLTIP_WITHOUT_ICON = "input-tooltip-without-icon", a.MANDATORY = "input-mandatory", a.LABEL_CONTAINER = "input-label-container", a.LABEL_TEXT = "input-label-text", a.FIELD = "input-field", a.EXTRA_TEXT = "input-extra-text", a.TOGGLE_PASSWORD = "input-toggle-password-icon", a))(r || {}), C = /* @__PURE__ */ ((a) => (a.WRAPPER = "ta-wrapper", a.LABEL = "ta-label", a.FIELD = "ta-field", a.TEXT = "ta-text", a))(C || {}), N = /* @__PURE__ */ ((a) => (a.CONTAINER = "search-container", a.FIELD = "search-field", a.CLOSE = "search-close", a.CLEAR = "search-clear", a))(N || {}), p = /* @__PURE__ */ ((a) => (a.CONTAINER = "tbl-container", a.TABLE = "tbl-table", a.HEADER = "tbl-header", a.TITLE = "tbl-title", a.HEADER_RIGHT = "tbl-header-right", a.ACTIONS = "tbl-actions", a.SECTIONS = "tbl-sections", a.BODY_WRAPPER = "tbl-body-wrapper", a.EMPTY_STATE = "tbl-empty-state", a))(p || {}), O = /* @__PURE__ */ ((a) => (a.TEXT = "tt-text", a.TRIGGER = "tt-trigger", a.HEADER = "tt-header", a))(O || {}), B = /* @__PURE__ */ ((a) => (a.WRAPPER = "tabs-wrapper", a.TAB = "tabs-tab", a))(B || {}), m = /* @__PURE__ */ ((a) => (a.CONTAINER = "field-label-container", a.TEXT = "field-label-text", a.MANDATORY = "field-label-mandatory", a.TOOLTIP = "field-label-help-tooltip", a))(m || {}), w = /* @__PURE__ */ ((a) => (a.CONTAINER = "field-help-text-container", a.TEXT = "field-help-text-text", a.ICON = "field-help-text-icon", a))(w || {}), y = /* @__PURE__ */ ((a) => (a.CONTAINER = "sb-container", a.TITLE = "sb-title", a.MESSAGE = "sb-message", a.CLOSE = "sb-close", a.ICON = "sb-icon", a.ACTION_BUTTON = "sb-action-button", a))(y || {}), E = /* @__PURE__ */ ((a) => (a.TITLE = "form-card-title", a.CONTENT = "form-card-content", a.ACTIONS = "form-card-actions", a.SAVE_BUTTON = "form-card-save-btn", a.CANCEL_BUTTON = "form-card-cancel-btn", a))(E || {}), b = /* @__PURE__ */ ((a) => (a.TITLE = "ah-title", a.APP_KEY = "ah-app-key", a.APP_PLATFORM = "ah-app-platform", a.AB_ICON = "ah-ab-icon", a))(b || {}), _ = /* @__PURE__ */ ((a) => (a.TEXT = "ic-text", a.COPY_BTN = "ic-copy-btn", a))(_ || {}), x = /* @__PURE__ */ ((a) => (a.WRAPPER = "multibar-wrapper", a.CLOSE_BTN = "multibar-close-button", a.MENU = "multibar-menu", a.ACTION = "multibar-action", a))(x || {}), T = /* @__PURE__ */ ((a) => (a.CONTAINER = "sortable-list-container", a.DRAGGABLE_LIST = "sortable-list-draggable-list", a.LOCKED_LIST = "sortable-list-locked-list", a))(T || {});
|
|
5
|
+
const U = (a, t) => {
|
|
6
6
|
const e = new URLSearchParams(a).toString();
|
|
7
7
|
return t.includes("?") ? `${t}${e}` : `${t}?${e}`;
|
|
8
8
|
}, V = (a, t = {}) => {
|
|
9
9
|
const e = [];
|
|
10
|
-
Object.entries(t).forEach(([
|
|
11
|
-
e.push(`${
|
|
10
|
+
Object.entries(t).forEach(([l, h]) => {
|
|
11
|
+
e.push(`${l}:${h}`);
|
|
12
12
|
});
|
|
13
13
|
const o = {
|
|
14
14
|
id: a,
|
|
15
15
|
viewMode: "story",
|
|
16
16
|
args: e.join(";")
|
|
17
17
|
};
|
|
18
|
-
return
|
|
18
|
+
return U(o, "iframe.html");
|
|
19
19
|
}, n = (a, t) => `${a}-${t}`;
|
|
20
|
-
class
|
|
20
|
+
class Q {
|
|
21
21
|
constructor(t) {
|
|
22
|
-
|
|
22
|
+
c(this, "page");
|
|
23
23
|
this.page = t;
|
|
24
24
|
}
|
|
25
25
|
async waitForComponent({ testId: t }) {
|
|
26
|
-
const e = `[data-testid='${t}-${
|
|
26
|
+
const e = `[data-testid='${t}-${R.WRAPPER}']`;
|
|
27
27
|
await this.page.waitForSelector(e);
|
|
28
28
|
}
|
|
29
29
|
getBannerText({ testId: t }) {
|
|
30
|
-
return this.page.getByTestId(n(t,
|
|
30
|
+
return this.page.getByTestId(n(t, R.CONTENT)).textContent();
|
|
31
31
|
}
|
|
32
32
|
hasBannerType({ testId: t, type: e }) {
|
|
33
|
-
return this.page.getByTestId(n(t,
|
|
33
|
+
return this.page.getByTestId(n(t, R.WRAPPER)).locator(`.icon.icon-name--${e}`) !== null;
|
|
34
34
|
}
|
|
35
35
|
}
|
|
36
|
-
class
|
|
36
|
+
class Z {
|
|
37
37
|
constructor(t) {
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
38
|
+
c(this, "page");
|
|
39
|
+
c(this, "testId");
|
|
40
|
+
c(this, "componentId");
|
|
41
|
+
c(this, "loadedPageSelector");
|
|
42
42
|
this.page = t.page, this.testId = t.testId, this.componentId = t.componentId, this.loadedPageSelector = t.loadedPageSelector;
|
|
43
43
|
}
|
|
44
44
|
async goto(t = {}) {
|
|
@@ -54,59 +54,59 @@ class z {
|
|
|
54
54
|
), await this.page.waitForSelector(this.loadedPageSelector);
|
|
55
55
|
}
|
|
56
56
|
}
|
|
57
|
-
class
|
|
57
|
+
class M {
|
|
58
58
|
constructor(t) {
|
|
59
|
-
|
|
59
|
+
c(this, "page");
|
|
60
60
|
this.page = t;
|
|
61
61
|
}
|
|
62
62
|
async waitForComponent({ testId: t }) {
|
|
63
|
-
const e = `[data-testid='${t}-${
|
|
63
|
+
const e = `[data-testid='${t}-${u.WRAPPER}']`;
|
|
64
64
|
await this.page.waitForSelector(e);
|
|
65
65
|
}
|
|
66
66
|
getDialogTitle({ testId: t }) {
|
|
67
|
-
return this.page.getByTestId(n(t,
|
|
67
|
+
return this.page.getByTestId(n(t, u.HEADER)).textContent();
|
|
68
68
|
}
|
|
69
69
|
getDialogText({ testId: t }) {
|
|
70
|
-
return this.page.getByTestId(n(t,
|
|
70
|
+
return this.page.getByTestId(n(t, u.CONTENT)).textContent();
|
|
71
71
|
}
|
|
72
72
|
async closeDialog({ testId: t }) {
|
|
73
73
|
await (await this.page.getByTestId(
|
|
74
|
-
n(t,
|
|
74
|
+
n(t, u.ACTION_CLOSE)
|
|
75
75
|
)).click();
|
|
76
76
|
}
|
|
77
77
|
async clickOnPrimaryButton({ testId: t }) {
|
|
78
78
|
await this.page.getByTestId(
|
|
79
|
-
n(t,
|
|
79
|
+
n(t, u.SAVE_BUTTON)
|
|
80
80
|
).click();
|
|
81
81
|
}
|
|
82
82
|
async clickOnDefaultButton({ testId: t }) {
|
|
83
83
|
await this.page.getByTestId(
|
|
84
|
-
n(t,
|
|
84
|
+
n(t, u.CANCEL_BUTTON)
|
|
85
85
|
).click();
|
|
86
86
|
}
|
|
87
87
|
async clickOnDeleteButton({ testId: t }) {
|
|
88
88
|
await (await this.page.getByTestId(
|
|
89
|
-
n(t,
|
|
89
|
+
n(t, u.ACTION_BUTTONS_WRAPPER)
|
|
90
90
|
).locator(".danger")).click();
|
|
91
91
|
}
|
|
92
92
|
getDialogSubtitle({ testId: t }) {
|
|
93
|
-
return this.page.getByTestId(n(t,
|
|
93
|
+
return this.page.getByTestId(n(t, u.HEADER_SECONDARY)).locator(".subtitle").textContent();
|
|
94
94
|
}
|
|
95
95
|
async isDialogVisible({ testId: t }) {
|
|
96
96
|
return await this.page.waitForTimeout(1e3), (await this.page.getByTestId(
|
|
97
|
-
n(t,
|
|
97
|
+
n(t, u.WRAPPER)
|
|
98
98
|
)).isVisible();
|
|
99
99
|
}
|
|
100
100
|
async waitForDialogToClose(t) {
|
|
101
101
|
await this.page.waitForSelector(
|
|
102
|
-
n(t,
|
|
102
|
+
n(t, u.WRAPPER),
|
|
103
103
|
{ state: "hidden" }
|
|
104
104
|
);
|
|
105
105
|
}
|
|
106
106
|
}
|
|
107
|
-
class
|
|
107
|
+
class G {
|
|
108
108
|
constructor(t) {
|
|
109
|
-
|
|
109
|
+
c(this, "page");
|
|
110
110
|
this.page = t;
|
|
111
111
|
}
|
|
112
112
|
async waitForComponent({ testId: t }) {
|
|
@@ -158,43 +158,43 @@ class D {
|
|
|
158
158
|
}
|
|
159
159
|
class A {
|
|
160
160
|
constructor(t) {
|
|
161
|
-
|
|
161
|
+
c(this, "page");
|
|
162
162
|
this.page = t;
|
|
163
163
|
}
|
|
164
164
|
getLabelText({ testId: t }) {
|
|
165
|
-
return this.page.getByTestId(n(t,
|
|
165
|
+
return this.page.getByTestId(n(t, m.TEXT)).textContent();
|
|
166
166
|
}
|
|
167
167
|
isMandatory({ testId: t }) {
|
|
168
|
-
return this.page.getByTestId(n(t,
|
|
168
|
+
return this.page.getByTestId(n(t, m.MANDATORY)).isVisible();
|
|
169
169
|
}
|
|
170
170
|
async getHelpIconText({ testId: t }) {
|
|
171
171
|
const e = await this.page.getByTestId(
|
|
172
|
-
n(t,
|
|
172
|
+
n(t, m.TOOLTIP)
|
|
173
173
|
);
|
|
174
174
|
return await e.hover(), e.getAttribute("text");
|
|
175
175
|
}
|
|
176
176
|
}
|
|
177
|
-
class
|
|
177
|
+
class F {
|
|
178
178
|
constructor(t) {
|
|
179
|
-
|
|
179
|
+
c(this, "page");
|
|
180
180
|
this.page = t;
|
|
181
181
|
}
|
|
182
182
|
hasExtraText({ testId: t }) {
|
|
183
|
-
return this.page.getByTestId(n(t,
|
|
183
|
+
return this.page.getByTestId(n(t, w.TEXT)).isVisible();
|
|
184
184
|
}
|
|
185
185
|
getExtraText({ testId: t }) {
|
|
186
|
-
return this.page.getByTestId(n(t,
|
|
186
|
+
return this.page.getByTestId(n(t, w.TEXT)).textContent();
|
|
187
187
|
}
|
|
188
188
|
async hasExtraTextIconType({ testId: t, type: e }) {
|
|
189
|
-
return await (await this.page.getByTestId(n(t,
|
|
189
|
+
return await (await this.page.getByTestId(n(t, w.CONTAINER)).locator(`.icon.icon-name--${e}`)).count() !== 0;
|
|
190
190
|
}
|
|
191
191
|
}
|
|
192
|
-
class
|
|
192
|
+
class X extends G {
|
|
193
193
|
constructor(e) {
|
|
194
194
|
super(e);
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
this.fieldLabelComponent = new A(e), this.fieldHelpTextComponent = new
|
|
195
|
+
c(this, "fieldLabelComponent");
|
|
196
|
+
c(this, "fieldHelpTextComponent");
|
|
197
|
+
this.fieldLabelComponent = new A(e), this.fieldHelpTextComponent = new F(e);
|
|
198
198
|
}
|
|
199
199
|
getDropdownTitle({ testId: e }) {
|
|
200
200
|
return this.fieldLabelComponent.getLabelText({ testId: e });
|
|
@@ -214,14 +214,23 @@ class f extends D {
|
|
|
214
214
|
hasExtraTextIconType({ testId: e, type: o }) {
|
|
215
215
|
return this.fieldHelpTextComponent.hasExtraTextIconType({ testId: e, type: o });
|
|
216
216
|
}
|
|
217
|
-
getSelectedLabel({ testId: e }) {
|
|
218
|
-
|
|
217
|
+
async getSelectedLabel({ testId: e }) {
|
|
218
|
+
let i = await this.page.getByTestId(n(e, s.BUTTON_CONTENT)).textContent();
|
|
219
|
+
if (await this.page.getByTestId(
|
|
220
|
+
n(e, s.BUTTON_CONTENT_SUFFIX)
|
|
221
|
+
).isVisible({ timeout: 1e3 })) {
|
|
222
|
+
const h = await this.page.getByTestId(
|
|
223
|
+
n(e, s.BUTTON_CONTENT_SUFFIX)
|
|
224
|
+
).textContent();
|
|
225
|
+
i = `${i}${h}`;
|
|
226
|
+
}
|
|
227
|
+
return i;
|
|
219
228
|
}
|
|
220
229
|
async searchForItem({ testId: e, searchTerm: o }) {
|
|
221
|
-
return await this.openDropdownComponent({ testId: e }), await this.page.getByTestId(n(e,
|
|
230
|
+
return await this.openDropdownComponent({ testId: e }), await this.page.getByTestId(n(e, r.FIELD)).fill(o), this.page.getByTestId(n(e, s.LIST_CONTAINER)).locator("ul > li span").first().textContent();
|
|
222
231
|
}
|
|
223
232
|
async isErrorText({ testId: e }) {
|
|
224
|
-
return await this.page.getByTestId(n(e,
|
|
233
|
+
return await this.page.getByTestId(n(e, w.TEXT)).count() > 0;
|
|
225
234
|
}
|
|
226
235
|
async isDisabled({ testId: e }) {
|
|
227
236
|
return (await this.page.getByTestId(n(e, s.TRIGGER)).locator(".button__container--disabled")).isVisible();
|
|
@@ -242,7 +251,7 @@ class f extends D {
|
|
|
242
251
|
return this.page.getByTestId(n(e, s.LIST_CONTAINER)).locator(".list").allTextContents();
|
|
243
252
|
}
|
|
244
253
|
}
|
|
245
|
-
class
|
|
254
|
+
class tt extends G {
|
|
246
255
|
constructor(t) {
|
|
247
256
|
super(t);
|
|
248
257
|
}
|
|
@@ -253,111 +262,111 @@ class Q extends D {
|
|
|
253
262
|
return this.page.getByTestId(n(t, s.TRIGGER)).locator("button > span").textContent();
|
|
254
263
|
}
|
|
255
264
|
async searchForItem({ testId: t, searchTerm: e }) {
|
|
256
|
-
return await this.openDropdownComponent({ testId: t }), await this.page.getByTestId(n(t,
|
|
265
|
+
return await this.openDropdownComponent({ testId: t }), await this.page.getByTestId(n(t, N.FIELD)).fill(e), this.page.getByTestId(n(t, s.LIST_CONTAINER)).locator("ul > li span").first().textContent();
|
|
257
266
|
}
|
|
258
267
|
}
|
|
259
|
-
class
|
|
268
|
+
class et {
|
|
260
269
|
constructor(t) {
|
|
261
|
-
|
|
270
|
+
c(this, "page");
|
|
262
271
|
this.page = t;
|
|
263
272
|
}
|
|
264
273
|
async waitForComponent({ testId: t }) {
|
|
265
|
-
const e = `[data-testid='${t}-${
|
|
274
|
+
const e = `[data-testid='${t}-${g.TRIGGER}']`;
|
|
266
275
|
await this.page.waitForSelector(e);
|
|
267
276
|
}
|
|
268
277
|
async clickOnApply(t) {
|
|
269
278
|
await this.page.getByTestId(
|
|
270
|
-
n(t,
|
|
279
|
+
n(t, g.ACTION_APPLY)
|
|
271
280
|
).click();
|
|
272
281
|
}
|
|
273
282
|
async clickOnCancel(t) {
|
|
274
283
|
await this.page.getByTestId(
|
|
275
|
-
n(t,
|
|
284
|
+
n(t, g.ACTION_CANCEL)
|
|
276
285
|
).click();
|
|
277
286
|
}
|
|
278
287
|
async openIncludeExcludeComponent(t) {
|
|
279
|
-
await this.page.getByTestId(n(t,
|
|
288
|
+
await this.page.getByTestId(n(t, g.TRIGGER)).click();
|
|
280
289
|
}
|
|
281
290
|
async searchForItem({ testId: t, searchTerm: e }) {
|
|
282
|
-
return await this.openIncludeExcludeComponent(t), await this.page.getByTestId(n(t,
|
|
291
|
+
return await this.openIncludeExcludeComponent(t), await this.page.getByTestId(n(t, g.SEARCH)).locator("input.transparent").fill(e), this.page.getByTestId(n(t, g.LIST)).locator("ul > li .v-popper span").first().textContent();
|
|
283
292
|
}
|
|
284
293
|
async selectItemByName({ testId: t, entityName: e }) {
|
|
285
|
-
await this.openIncludeExcludeComponent(t), await this.page.getByTestId(n(t,
|
|
294
|
+
await this.openIncludeExcludeComponent(t), await this.page.getByTestId(n(t, g.LIST)).locator("ul > li .v-popper span", { hasText: e }).first().click(), await this.clickOnApply(t);
|
|
286
295
|
}
|
|
287
296
|
async selectItemByIndex({ testId: t, index: e, applyChanges: o }) {
|
|
288
|
-
await this.clearAll({ testId: t }), await this.openIncludeExcludeComponent(t), await this.page.getByTestId(n(t,
|
|
297
|
+
await this.clearAll({ testId: t }), await this.openIncludeExcludeComponent(t), await this.page.getByTestId(n(t, g.LIST)).locator(".include-exclude-list ul > li").nth(e).click(), await this.page.waitForSelector("include-exclude-list-header-loading", {
|
|
289
298
|
state: "hidden"
|
|
290
299
|
}), o && await this.clickOnApply(t);
|
|
291
300
|
}
|
|
292
301
|
async selectMultipleItems({ testId: t, itemsToSelect: e }) {
|
|
293
302
|
await this.clearAll({ testId: t }), await this.openIncludeExcludeComponent(t);
|
|
294
303
|
for (const o of e)
|
|
295
|
-
await this.page.getByTestId(n(t,
|
|
304
|
+
await this.page.getByTestId(n(t, g.LIST)).locator(".include-exclude-list ul > li").nth(o).click();
|
|
296
305
|
}
|
|
297
306
|
async unselectItemByName({ testId: t, entityName: e }) {
|
|
298
307
|
await this.openIncludeExcludeComponent(t), await this.page.getByTestId(
|
|
299
|
-
n(t,
|
|
308
|
+
n(t, g.LIST_SELECTED)
|
|
300
309
|
).locator("ul > li", { hasText: e }).locator(".clear-button").click(), await this.clickOnApply(t);
|
|
301
310
|
}
|
|
302
311
|
async unselectByIndex({ testId: t, index: e, applyChanges: o }) {
|
|
303
312
|
await this.page.getByTestId(
|
|
304
|
-
n(t,
|
|
313
|
+
n(t, g.LIST_SELECTED)
|
|
305
314
|
).locator("ul li button").nth(e).click(), o && await this.clickOnApply(t);
|
|
306
315
|
}
|
|
307
316
|
async getSelectedCounter(t) {
|
|
308
317
|
return await this.page.getByTestId(
|
|
309
|
-
n(t,
|
|
318
|
+
n(t, g.LIST_SELECTED)
|
|
310
319
|
).locator(".include-exclude-selected-header-left span").textContent();
|
|
311
320
|
}
|
|
312
321
|
async clearAll({ testId: t }) {
|
|
313
|
-
await this.openIncludeExcludeComponent(t), await this.page.getByTestId(n(t,
|
|
322
|
+
await this.openIncludeExcludeComponent(t), await this.page.getByTestId(n(t, g.CLEAR_ALL)).click(), await this.clickOnApply(t);
|
|
314
323
|
}
|
|
315
324
|
getTriggerText({ testId: t }) {
|
|
316
|
-
return this.page.getByTestId(n(t,
|
|
325
|
+
return this.page.getByTestId(n(t, g.TRIGGER)).locator(".include-exclude-trigger-middle-section .container span").first().textContent();
|
|
317
326
|
}
|
|
318
327
|
getTriggerDescription({ testId: t }) {
|
|
319
|
-
return this.page.getByTestId(n(t,
|
|
328
|
+
return this.page.getByTestId(n(t, g.TRIGGER)).locator("div span.include-exclude-trigger-description").first().textContent();
|
|
320
329
|
}
|
|
321
330
|
async selectAll({ testId: t }) {
|
|
322
|
-
await this.openIncludeExcludeComponent(t), await this.page.getByTestId(n(t,
|
|
331
|
+
await this.openIncludeExcludeComponent(t), await this.page.getByTestId(n(t, g.SELECT_ALL)).click(), await this.clickOnApply(t);
|
|
323
332
|
}
|
|
324
333
|
}
|
|
325
|
-
class
|
|
334
|
+
class f {
|
|
326
335
|
constructor(t) {
|
|
327
|
-
|
|
336
|
+
c(this, "page");
|
|
328
337
|
this.page = t;
|
|
329
338
|
}
|
|
330
339
|
getInputsFieldText({ testId: t }) {
|
|
331
|
-
return this.page.getByTestId(n(t,
|
|
340
|
+
return this.page.getByTestId(n(t, r.FIELD)).inputValue();
|
|
332
341
|
}
|
|
333
342
|
getPlaceholderText({ testId: t }) {
|
|
334
|
-
return this.page.getByTestId(n(t,
|
|
343
|
+
return this.page.getByTestId(n(t, r.FIELD)).getAttribute("placeholder");
|
|
335
344
|
}
|
|
336
345
|
getInputsType({ testId: t }) {
|
|
337
|
-
return this.page.getByTestId(n(t,
|
|
346
|
+
return this.page.getByTestId(n(t, r.FIELD)).getAttribute("type");
|
|
338
347
|
}
|
|
339
348
|
async addInput({ testId: t, text: e }) {
|
|
340
|
-
await this.page.getByTestId(n(t,
|
|
349
|
+
await this.page.getByTestId(n(t, r.FIELD)).type(e);
|
|
341
350
|
}
|
|
342
351
|
async clearInput({ testId: t }) {
|
|
343
|
-
await this.page.getByTestId(n(t,
|
|
352
|
+
await this.page.getByTestId(n(t, r.FIELD)).clear();
|
|
344
353
|
}
|
|
345
354
|
isDisabled({ testId: t }) {
|
|
346
|
-
return this.page.getByTestId(n(t,
|
|
355
|
+
return this.page.getByTestId(n(t, r.FIELD)).isDisabled();
|
|
347
356
|
}
|
|
348
357
|
}
|
|
349
|
-
class
|
|
358
|
+
class at extends f {
|
|
350
359
|
constructor(e) {
|
|
351
360
|
super(e);
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
this.fieldLabelComponent = new A(e), this.fieldHelpTextComponent = new
|
|
361
|
+
c(this, "fieldLabelComponent");
|
|
362
|
+
c(this, "fieldHelpTextComponent");
|
|
363
|
+
this.fieldLabelComponent = new A(e), this.fieldHelpTextComponent = new F(e);
|
|
355
364
|
}
|
|
356
365
|
getInputsLabelText({ testId: e }) {
|
|
357
366
|
return this.fieldLabelComponent.getLabelText({ testId: e });
|
|
358
367
|
}
|
|
359
368
|
async waitForComponent({ testId: e }) {
|
|
360
|
-
const o = `[data-testid='${e}-${
|
|
369
|
+
const o = `[data-testid='${e}-${r.WRAPPER}']`;
|
|
361
370
|
await this.page.waitForSelector(o);
|
|
362
371
|
}
|
|
363
372
|
isInputMandatory({ testId: e }) {
|
|
@@ -370,32 +379,38 @@ class M extends H {
|
|
|
370
379
|
return this.fieldHelpTextComponent.getExtraText({ testId: e });
|
|
371
380
|
}
|
|
372
381
|
async clickOnApplyButton({ testId: e }) {
|
|
373
|
-
await (await this.page.getByTestId(n(e,
|
|
382
|
+
await (await this.page.getByTestId(n(e, r.WRAPPER)).locator(".icon.icon-name--check")).click();
|
|
374
383
|
}
|
|
375
|
-
hasInlineErrorText({
|
|
376
|
-
|
|
384
|
+
hasInlineErrorText({
|
|
385
|
+
testId: e,
|
|
386
|
+
inputTestId: o
|
|
387
|
+
}) {
|
|
388
|
+
return this.page.getByTestId(n(e, o)).isVisible();
|
|
377
389
|
}
|
|
378
|
-
async getInlineErrorText({
|
|
379
|
-
|
|
380
|
-
|
|
390
|
+
async getInlineErrorText({
|
|
391
|
+
testId: e,
|
|
392
|
+
inputTestId: o
|
|
393
|
+
}) {
|
|
394
|
+
const i = this.page.getByTestId(
|
|
395
|
+
n(e, o)
|
|
381
396
|
);
|
|
382
|
-
return await
|
|
397
|
+
return await i.hover(), i.getAttribute("text");
|
|
383
398
|
}
|
|
384
399
|
async clickOnShowPassword({ testId: e }) {
|
|
385
400
|
await this.isPasswordHidden({ testId: e }) && await this.clickOnPasswordIcon({ testId: e });
|
|
386
401
|
}
|
|
387
402
|
async clickOnPasswordIcon({ testId: e }) {
|
|
388
|
-
await this.page.getByTestId(n(e,
|
|
403
|
+
await this.page.getByTestId(n(e, r.TOGGLE_PASSWORD)).click();
|
|
389
404
|
}
|
|
390
405
|
async clickOnHidePassword({ testId: e }) {
|
|
391
406
|
await this.isPasswordHidden({ testId: e }) || await this.clickOnPasswordIcon({ testId: e });
|
|
392
407
|
}
|
|
393
408
|
isPasswordHidden({ testId: e }) {
|
|
394
|
-
return this.page.getByTestId(n(e,
|
|
409
|
+
return this.page.getByTestId(n(e, r.TOGGLE_PASSWORD)).locator(".icon.icon-name--eye-slash").isVisible();
|
|
395
410
|
}
|
|
396
411
|
async clearInput({ testId: e }) {
|
|
397
412
|
await (await this.page.getByTestId(
|
|
398
|
-
n(e,
|
|
413
|
+
n(e, r.FIELD)
|
|
399
414
|
)).clear();
|
|
400
415
|
}
|
|
401
416
|
hasExtraTextIconType({ testId: e, type: o }) {
|
|
@@ -403,11 +418,11 @@ class M extends H {
|
|
|
403
418
|
}
|
|
404
419
|
async isDisabled({ testId: e }) {
|
|
405
420
|
return (await this.page.getByTestId(
|
|
406
|
-
n(e,
|
|
421
|
+
n(e, r.FIELD)
|
|
407
422
|
)).isDisabled();
|
|
408
423
|
}
|
|
409
424
|
hasApplyButton({ testId: e }) {
|
|
410
|
-
return this.page.getByTestId(n(e,
|
|
425
|
+
return this.page.getByTestId(n(e, r.WRAPPER)).locator(".icon.icon-name--check").isVisible();
|
|
411
426
|
}
|
|
412
427
|
async getMaxLengthNumber({ testId: e }) {
|
|
413
428
|
return (await this.getFontCaptionText({ testId: e }))[1];
|
|
@@ -416,155 +431,155 @@ class M extends H {
|
|
|
416
431
|
return (await this.getFontCaptionText({ testId: e }))[0];
|
|
417
432
|
}
|
|
418
433
|
async getFontCaptionText({ testId: e }) {
|
|
419
|
-
return (await this.page.getByTestId(n(e,
|
|
434
|
+
return (await this.page.getByTestId(n(e, r.WRAPPER)).locator(".font-caption").textContent()).split("/").map((i) => parseInt(i.trim(), 10));
|
|
420
435
|
}
|
|
421
436
|
getHelpIconText({ testId: e }) {
|
|
422
437
|
return this.fieldLabelComponent.getHelpIconText({ testId: e });
|
|
423
438
|
}
|
|
424
439
|
async isValidationAppear({ testId: e }) {
|
|
425
|
-
return (await this.page.getByTestId(n(e,
|
|
440
|
+
return (await this.page.getByTestId(n(e, r.WRAPPER)).getAttribute("class")).includes("variant-error");
|
|
426
441
|
}
|
|
427
442
|
}
|
|
428
|
-
class
|
|
443
|
+
class nt {
|
|
429
444
|
constructor(t) {
|
|
430
|
-
|
|
445
|
+
c(this, "page");
|
|
431
446
|
this.page = t;
|
|
432
447
|
}
|
|
433
448
|
async waitForComponent({ testId: t }) {
|
|
434
|
-
const e = `[data-testid='${t}-${
|
|
449
|
+
const e = `[data-testid='${t}-${B.WRAPPER}']`;
|
|
435
450
|
await this.page.waitForSelector(e);
|
|
436
451
|
}
|
|
437
452
|
getSelectedTabText({ testId: t }) {
|
|
438
|
-
return this.page.getByTestId(n(t,
|
|
453
|
+
return this.page.getByTestId(n(t, B.WRAPPER)).locator(".tab-item--active").textContent();
|
|
439
454
|
}
|
|
440
455
|
async selectTab({ testId: t, tabName: e }) {
|
|
441
456
|
const o = await this.getTabIndex({ testId: t, tabName: e });
|
|
442
457
|
await this.page.getByTestId(
|
|
443
|
-
n(t, `${
|
|
458
|
+
n(t, `${B.TAB}-${o + 1}`)
|
|
444
459
|
).click();
|
|
445
460
|
}
|
|
446
461
|
async getTabIndex({ testId: t, tabName: e }) {
|
|
447
|
-
return (await this.page.getByTestId(n(t,
|
|
462
|
+
return (await this.page.getByTestId(n(t, B.WRAPPER)).locator(".tab-item").allTextContents()).indexOf(e);
|
|
448
463
|
}
|
|
449
464
|
async isTabDisabled({ testId: t, tabName: e }) {
|
|
450
465
|
const o = await this.getTabIndex({ testId: t, tabName: e });
|
|
451
|
-
return this.page.getByTestId(n(t, `${
|
|
466
|
+
return this.page.getByTestId(n(t, `${B.TAB}-${o}`)).locator(".tab-item--disabled").isVisible();
|
|
452
467
|
}
|
|
453
468
|
}
|
|
454
|
-
class
|
|
469
|
+
class ot {
|
|
455
470
|
constructor(t) {
|
|
456
|
-
|
|
471
|
+
c(this, "page");
|
|
457
472
|
this.page = t;
|
|
458
473
|
}
|
|
459
474
|
async waitForComponent({ testId: t }) {
|
|
460
|
-
const e = `[data-testid='${t}-${
|
|
475
|
+
const e = `[data-testid='${t}-${O.TRIGGER}']`;
|
|
461
476
|
await this.page.waitForSelector(e);
|
|
462
477
|
}
|
|
463
478
|
getTooltipText({ testId: t }) {
|
|
464
|
-
return this.page.getByTestId(`${t}-${
|
|
479
|
+
return this.page.getByTestId(`${t}-${O.TRIGGER}`).getAttribute("text");
|
|
465
480
|
}
|
|
466
481
|
getTooltipHeaderText({ testId: t }) {
|
|
467
|
-
return this.page.getByTestId(`${t}-${
|
|
482
|
+
return this.page.getByTestId(`${t}-${O.TRIGGER}`).getAttribute("header");
|
|
468
483
|
}
|
|
469
484
|
}
|
|
470
|
-
const
|
|
471
|
-
class
|
|
485
|
+
const I = ".table-row", S = ".icon-wrapper", $ = ".states", P = ".table-head-container", H = ".table-row.loading", Y = 1e3;
|
|
486
|
+
class it {
|
|
472
487
|
constructor(t) {
|
|
473
|
-
|
|
488
|
+
c(this, "page");
|
|
474
489
|
this.page = t;
|
|
475
490
|
}
|
|
476
491
|
async waitForComponent({ testId: t }) {
|
|
477
|
-
const e = `[data-testid='${t}-${
|
|
492
|
+
const e = `[data-testid='${t}-${p.CONTAINER}']`;
|
|
478
493
|
await this.page.waitForSelector(e);
|
|
479
494
|
}
|
|
480
495
|
getTableRowCount({ testId: t }) {
|
|
481
|
-
return this.page.getByTestId(n(t,
|
|
496
|
+
return this.page.getByTestId(n(t, p.BODY_WRAPPER)).locator(I).count();
|
|
482
497
|
}
|
|
483
498
|
async getColumnHeaders({ testId: t }) {
|
|
484
|
-
return this.page.getByTestId(n(t,
|
|
499
|
+
return this.page.getByTestId(n(t, p.TABLE)).locator(P).allTextContents();
|
|
485
500
|
}
|
|
486
501
|
getTableLabel({ testId: t }) {
|
|
487
|
-
return this.page.getByTestId(n(t,
|
|
502
|
+
return this.page.getByTestId(n(t, p.HEADER)).innerText();
|
|
488
503
|
}
|
|
489
504
|
getTableFooter({ testId: t }) {
|
|
490
|
-
return this.page.getByTestId(n(t,
|
|
505
|
+
return this.page.getByTestId(n(t, p.CONTAINER)).locator(".table-footer").innerText();
|
|
491
506
|
}
|
|
492
507
|
async clickOnHeaderByName(t) {
|
|
493
|
-
await this.page.locator(
|
|
508
|
+
await this.page.locator(P, {
|
|
494
509
|
hasText: t
|
|
495
510
|
}).click();
|
|
496
511
|
}
|
|
497
512
|
async searchForItems({ testId: t, searchTerm: e }) {
|
|
498
|
-
await this.clearSearchText({ testId: t }), await this.page.getByTestId(n(t,
|
|
513
|
+
await this.clearSearchText({ testId: t }), await this.page.getByTestId(n(t, r.FIELD)).fill(e);
|
|
499
514
|
}
|
|
500
515
|
async clearSearchText({ testId: t }) {
|
|
501
|
-
await this.page.getByTestId(n(t,
|
|
516
|
+
await this.page.getByTestId(n(t, r.FIELD)).clear(), await this.waitForTableToLoad();
|
|
502
517
|
}
|
|
503
518
|
isArrowVisible({ testId: t, headerName: e }) {
|
|
504
|
-
return this.page.getByTestId(n(t,
|
|
519
|
+
return this.page.getByTestId(n(t, p.TABLE)).locator(P, { hasText: e }).locator(".table-sort-icon").isVisible();
|
|
505
520
|
}
|
|
506
521
|
async scrollDownTableRows({ testId: t }) {
|
|
507
522
|
const e = `[data-testid=${n(
|
|
508
523
|
t,
|
|
509
|
-
|
|
524
|
+
p.TABLE
|
|
510
525
|
)}]`;
|
|
511
526
|
await this.page.focus(e), await this.page.evaluate((o) => {
|
|
512
|
-
const
|
|
513
|
-
|
|
514
|
-
}, e), await this.page.waitForTimeout(
|
|
527
|
+
const i = document.querySelector(o);
|
|
528
|
+
i && (i.scrollTop = i.scrollHeight);
|
|
529
|
+
}, e), await this.page.waitForTimeout(Y);
|
|
515
530
|
}
|
|
516
531
|
async waitForTableToLoad() {
|
|
517
|
-
await this.page.waitForSelector(
|
|
532
|
+
await this.page.waitForSelector(H, {
|
|
518
533
|
state: "hidden"
|
|
519
534
|
});
|
|
520
535
|
}
|
|
521
536
|
async waitingForTableLoadingToAppear() {
|
|
522
|
-
await this.page.waitForSelector(
|
|
537
|
+
await this.page.waitForSelector(H);
|
|
523
538
|
}
|
|
524
539
|
async expandRow({ testId: t, rowValue: e }) {
|
|
525
|
-
await this.page.getByTestId(n(t,
|
|
540
|
+
await this.page.getByTestId(n(t, p.BODY_WRAPPER)).locator(I, { hasText: e }).locator(S).click();
|
|
526
541
|
}
|
|
527
542
|
isRowExpanded({ testId: t, rowValue: e }) {
|
|
528
|
-
return this.page.getByTestId(n(t,
|
|
543
|
+
return this.page.getByTestId(n(t, p.BODY_WRAPPER)).locator(I, { hasText: e }).locator(S).isVisible();
|
|
529
544
|
}
|
|
530
545
|
async getExpandedRowContent({ testId: t, rowValue: e }) {
|
|
531
546
|
return await this.isRowExpanded({
|
|
532
547
|
testId: t,
|
|
533
548
|
rowValue: e
|
|
534
|
-
}) || await this.expandRow({ testId: t, rowValue: e }), this.page.getByTestId(n(t,
|
|
549
|
+
}) || await this.expandRow({ testId: t, rowValue: e }), this.page.getByTestId(n(t, p.BODY_WRAPPER)).locator(I, { hasText: e }).locator(S).textContent();
|
|
535
550
|
}
|
|
536
551
|
isEmptyStateVisible({ testId: t }) {
|
|
537
|
-
return this.page.getByTestId(n(t,
|
|
552
|
+
return this.page.getByTestId(n(t, p.TABLE)).locator(".empty-state").isVisible();
|
|
538
553
|
}
|
|
539
554
|
getEmptyStateTitle({ testId: t }) {
|
|
540
|
-
return this.page.getByTestId(n(t,
|
|
555
|
+
return this.page.getByTestId(n(t, p.TABLE)).locator(".font-heading-4.title").textContent();
|
|
541
556
|
}
|
|
542
557
|
getEmptyStateSubtitle({ testId: t }) {
|
|
543
|
-
return this.page.getByTestId(n(t,
|
|
558
|
+
return this.page.getByTestId(n(t, p.TABLE)).locator(".font-body-1.subtitle").textContent();
|
|
544
559
|
}
|
|
545
560
|
async clickOnRowCheckboxByRowValue({ testId: t, rowValue: e }) {
|
|
546
|
-
await this.page.getByTestId(n(t,
|
|
561
|
+
await this.page.getByTestId(n(t, p.TABLE)).locator(I, {
|
|
547
562
|
hasText: e
|
|
548
|
-
}).locator(
|
|
563
|
+
}).locator($).click();
|
|
549
564
|
}
|
|
550
565
|
getCheckedRowsNumber({ testId: t }) {
|
|
551
|
-
return this.page.getByTestId(n(t,
|
|
566
|
+
return this.page.getByTestId(n(t, p.TABLE)).locator(I).locator(".icon.checked").count();
|
|
552
567
|
}
|
|
553
568
|
async clickOnSelectAllCheckbox({ testId: t }) {
|
|
554
|
-
await this.page.getByTestId(n(t,
|
|
569
|
+
await this.page.getByTestId(n(t, p.TABLE)).locator($).nth(0).click();
|
|
555
570
|
}
|
|
556
571
|
getTableLocator({ testId: t }) {
|
|
557
572
|
return this.page.getByTestId(
|
|
558
|
-
n(t,
|
|
573
|
+
n(t, p.CONTAINER)
|
|
559
574
|
);
|
|
560
575
|
}
|
|
561
576
|
getColumnContentByHeaderName({ testId: t, headerName: e }) {
|
|
562
577
|
return this.getTableLocator({ testId: t }).locator(e).allTextContents();
|
|
563
578
|
}
|
|
564
579
|
}
|
|
565
|
-
class
|
|
580
|
+
class K {
|
|
566
581
|
constructor(t) {
|
|
567
|
-
|
|
582
|
+
c(this, "page");
|
|
568
583
|
this.page = t;
|
|
569
584
|
}
|
|
570
585
|
async waitForComponent({ testId: t }) {
|
|
@@ -584,76 +599,76 @@ class X {
|
|
|
584
599
|
return this.page.getByTestId(t).isDisabled();
|
|
585
600
|
}
|
|
586
601
|
}
|
|
587
|
-
class
|
|
602
|
+
class st {
|
|
588
603
|
constructor(t) {
|
|
589
|
-
|
|
604
|
+
c(this, "page");
|
|
590
605
|
this.page = t;
|
|
591
606
|
}
|
|
592
607
|
async waitForComponent({ testId: t }) {
|
|
593
|
-
const e = `[data-testid='${t}-${
|
|
608
|
+
const e = `[data-testid='${t}-${y.CONTAINER}']`;
|
|
594
609
|
await this.page.waitForSelector(e);
|
|
595
610
|
}
|
|
596
611
|
getSnackbarTitle({ testId: t }) {
|
|
597
|
-
return this.page.getByTestId(n(t,
|
|
612
|
+
return this.page.getByTestId(n(t, y.TITLE)).textContent();
|
|
598
613
|
}
|
|
599
614
|
async closeSnackbar({ testId: t }) {
|
|
600
|
-
await this.page.getByTestId(n(t,
|
|
615
|
+
await this.page.getByTestId(n(t, y.CLOSE)).locator(".icon-name--x").click();
|
|
601
616
|
}
|
|
602
617
|
async waitForSnackbarToBeClosed({ testId: t }) {
|
|
603
|
-
const e = `[data-testid='${t}-${
|
|
618
|
+
const e = `[data-testid='${t}-${y.CONTAINER}']`;
|
|
604
619
|
await this.page.waitForSelector(e, { state: "detached" });
|
|
605
620
|
}
|
|
606
621
|
getSnackbarDescription({ testId: t }) {
|
|
607
|
-
return this.page.getByTestId(n(t,
|
|
622
|
+
return this.page.getByTestId(n(t, y.MESSAGE)).textContent();
|
|
608
623
|
}
|
|
609
624
|
async clickOnActionButton({ testId: t, buttonName: e }) {
|
|
610
625
|
const o = await this.getActionButtonIndex({
|
|
611
626
|
testId: t,
|
|
612
627
|
buttonName: e
|
|
613
|
-
}),
|
|
614
|
-
await this.page.click(
|
|
628
|
+
}), i = `[data-testid='${t}-${y.ACTION_BUTTON}-${o}']`;
|
|
629
|
+
await this.page.click(i);
|
|
615
630
|
}
|
|
616
631
|
async getActionButtonIndex({
|
|
617
632
|
testId: t,
|
|
618
633
|
buttonName: e
|
|
619
634
|
}) {
|
|
620
|
-
return (await this.page.getByTestId(n(t,
|
|
635
|
+
return (await this.page.getByTestId(n(t, y.CONTAINER)).locator(".font-button").allTextContents()).indexOf(e);
|
|
621
636
|
}
|
|
622
637
|
}
|
|
623
|
-
class
|
|
638
|
+
class rt {
|
|
624
639
|
constructor(t) {
|
|
625
|
-
|
|
640
|
+
c(this, "page");
|
|
626
641
|
this.page = t;
|
|
627
642
|
}
|
|
628
643
|
async waitForComponent({ testId: t }) {
|
|
629
|
-
const e = `[data-testid='${t}-${
|
|
644
|
+
const e = `[data-testid='${t}-${x.WRAPPER}']`;
|
|
630
645
|
await this.page.waitForSelector(e);
|
|
631
646
|
}
|
|
632
647
|
async closeMultiBar({ testId: t }) {
|
|
633
|
-
await this.page.getByTestId(n(t,
|
|
648
|
+
await this.page.getByTestId(n(t, x.CLOSE_BTN)).locator(".icon-wrapper").click();
|
|
634
649
|
}
|
|
635
650
|
getMultiBarCountText({ testId: t }) {
|
|
636
|
-
return this.page.getByTestId(n(t,
|
|
651
|
+
return this.page.getByTestId(n(t, x.WRAPPER)).locator(".count-text").textContent();
|
|
637
652
|
}
|
|
638
653
|
async isMultiBarVisible({ testId: t }) {
|
|
639
|
-
return await this.page.waitForTimeout(1e3), this.page.getByTestId(n(t,
|
|
654
|
+
return await this.page.waitForTimeout(1e3), this.page.getByTestId(n(t, x.WRAPPER)).locator(".multi-bar-panel").isVisible();
|
|
640
655
|
}
|
|
641
656
|
async clickOnActionButton({ testId: t, actionButtonId: e }) {
|
|
642
657
|
await this.page.getByTestId(
|
|
643
658
|
n(
|
|
644
659
|
t,
|
|
645
|
-
`${
|
|
660
|
+
`${x.ACTION}-${e}`
|
|
646
661
|
)
|
|
647
662
|
).locator(".start-icon").click();
|
|
648
663
|
}
|
|
649
664
|
}
|
|
650
|
-
class
|
|
665
|
+
class ct {
|
|
651
666
|
constructor(t) {
|
|
652
|
-
|
|
667
|
+
c(this, "page");
|
|
653
668
|
this.page = t;
|
|
654
669
|
}
|
|
655
670
|
async waitForComponent({ testId: t }) {
|
|
656
|
-
const e = `[data-testid='${t}-${
|
|
671
|
+
const e = `[data-testid='${t}-${m.TEXT}']`;
|
|
657
672
|
await this.page.waitForSelector(e);
|
|
658
673
|
}
|
|
659
674
|
getFormRowTitle({ testId: t }) {
|
|
@@ -663,140 +678,140 @@ class it {
|
|
|
663
678
|
return new A(this.page).isMandatory({ testId: t });
|
|
664
679
|
}
|
|
665
680
|
getIconText({ testId: t }) {
|
|
666
|
-
return new
|
|
681
|
+
return new F(this.page).getExtraText({ testId: t });
|
|
667
682
|
}
|
|
668
683
|
}
|
|
669
|
-
class
|
|
684
|
+
class lt {
|
|
670
685
|
constructor(t) {
|
|
671
|
-
|
|
686
|
+
c(this, "page");
|
|
672
687
|
this.page = t;
|
|
673
688
|
}
|
|
674
689
|
async waitForComponent({ testId: t }) {
|
|
675
|
-
const e = `[data-testid='${t}-${
|
|
690
|
+
const e = `[data-testid='${t}-${E.CONTENT}']`;
|
|
676
691
|
await this.page.waitForSelector(e);
|
|
677
692
|
}
|
|
678
693
|
getCardTitle({ testId: t }) {
|
|
679
|
-
return this.page.getByTestId(n(t,
|
|
694
|
+
return this.page.getByTestId(n(t, E.TITLE)).textContent();
|
|
680
695
|
}
|
|
681
696
|
getCardContentText({ testId: t }) {
|
|
682
|
-
return this.page.getByTestId(n(t,
|
|
697
|
+
return this.page.getByTestId(n(t, E.CONTENT)).textContent();
|
|
683
698
|
}
|
|
684
699
|
getCardLabelText({ testId: t }) {
|
|
685
700
|
return new A(this.page).getLabelText({ testId: t });
|
|
686
701
|
}
|
|
687
702
|
async clickOnSaveButton({ testId: t }) {
|
|
688
|
-
await this.page.getByTestId(n(t,
|
|
703
|
+
await this.page.getByTestId(n(t, E.SAVE_BUTTON)).click();
|
|
689
704
|
}
|
|
690
705
|
async clickOnCancelButton({ testId: t }) {
|
|
691
|
-
await this.page.getByTestId(n(t,
|
|
706
|
+
await this.page.getByTestId(n(t, E.CANCEL_BUTTON)).click();
|
|
692
707
|
}
|
|
693
708
|
isSaveButtonLoading({ testId: t }) {
|
|
694
|
-
return new
|
|
709
|
+
return new K(this.page).isButtonLoading({ testId: t });
|
|
695
710
|
}
|
|
696
711
|
async clearForm({
|
|
697
712
|
testId: t,
|
|
698
713
|
inputType: e
|
|
699
714
|
}) {
|
|
700
|
-
(await this.page.getByTestId(n(t,
|
|
715
|
+
(await this.page.getByTestId(n(t, E.CONTENT)).locator(
|
|
701
716
|
`[data-testid='ad-units-form-card-form-card-content'] input[type='${e}']`
|
|
702
|
-
).all()).forEach((
|
|
717
|
+
).all()).forEach((i) => i.clear());
|
|
703
718
|
}
|
|
704
719
|
}
|
|
705
|
-
class
|
|
720
|
+
class L extends f {
|
|
706
721
|
constructor(t) {
|
|
707
722
|
super(t);
|
|
708
723
|
}
|
|
709
724
|
async waitForComponent({ testId: t }) {
|
|
710
|
-
const e = `[data-testid='${t}-${
|
|
725
|
+
const e = `[data-testid='${t}-${r.WRAPPER}']`;
|
|
711
726
|
await this.page.waitForSelector(e);
|
|
712
727
|
}
|
|
713
728
|
async isViewOnly({ testId: t }) {
|
|
714
|
-
return await this.page.getByTestId(n(t,
|
|
729
|
+
return await this.page.getByTestId(n(t, r.WRAPPER)).locator(".view-only.input-type").count() > 0;
|
|
715
730
|
}
|
|
716
731
|
getLabel({ testId: t }) {
|
|
717
|
-
return this.page.getByTestId(n(t,
|
|
732
|
+
return this.page.getByTestId(n(t, r.LABEL_TEXT)).textContent();
|
|
718
733
|
}
|
|
719
734
|
isInputMandatory({ testId: t }) {
|
|
720
|
-
return this.page.getByTestId(n(t,
|
|
735
|
+
return this.page.getByTestId(n(t, r.MANDATORY)).isVisible();
|
|
721
736
|
}
|
|
722
737
|
hasInputExtraHelpText({ testId: t }) {
|
|
723
|
-
return this.page.getByTestId(n(t,
|
|
738
|
+
return this.page.getByTestId(n(t, r.EXTRA_TEXT)).isVisible();
|
|
724
739
|
}
|
|
725
740
|
async getHelpIconText({ testId: t }) {
|
|
726
|
-
const e = await this.page.getByTestId(n(t,
|
|
741
|
+
const e = await this.page.getByTestId(n(t, r.LABEL_CONTAINER)).locator(".v-popper.v-popper--theme-default");
|
|
727
742
|
return await e.hover(), e.getAttribute("text");
|
|
728
743
|
}
|
|
729
744
|
getInputExtraText({ testId: t }) {
|
|
730
|
-
return this.page.getByTestId(n(t,
|
|
745
|
+
return this.page.getByTestId(n(t, r.EXTRA_TEXT)).textContent();
|
|
731
746
|
}
|
|
732
747
|
getErrorExtraText({ testId: t }) {
|
|
733
|
-
return this.page.getByTestId(n(t,
|
|
748
|
+
return this.page.getByTestId(n(t, r.EXTRA_TEXT)).locator(".error").textContent();
|
|
734
749
|
}
|
|
735
750
|
async showPassword({ testId: t }) {
|
|
736
751
|
await this.isPasswordHidden({ testId: t }) && await this.clickOnPasswordButton({ testId: t });
|
|
737
752
|
}
|
|
738
753
|
async isPasswordHidden({ testId: t }) {
|
|
739
|
-
return await this.page.getByTestId(n(t,
|
|
754
|
+
return await this.page.getByTestId(n(t, r.WRAPPER)).getAttribute("type") === "password";
|
|
740
755
|
}
|
|
741
756
|
async clickOnPasswordButton({ testId: t }) {
|
|
742
|
-
await (await this.page.getByTestId(n(t,
|
|
757
|
+
await (await this.page.getByTestId(n(t, r.WRAPPER)).locator(".password-visibility")).click();
|
|
743
758
|
}
|
|
744
759
|
}
|
|
745
|
-
class
|
|
760
|
+
class pt {
|
|
746
761
|
constructor(t) {
|
|
747
|
-
|
|
762
|
+
c(this, "page");
|
|
748
763
|
this.page = t;
|
|
749
764
|
}
|
|
750
765
|
async waitForComponent({ testId: t }) {
|
|
751
|
-
const e = `[data-testid='${t}-${
|
|
766
|
+
const e = `[data-testid='${t}-${N.CONTAINER}']`;
|
|
752
767
|
await this.page.waitForSelector(e);
|
|
753
768
|
}
|
|
754
769
|
async searchInput({ testId: t, searchTerm: e }) {
|
|
755
|
-
await new
|
|
770
|
+
await new L(this.page).addInput({ testId: t, text: e });
|
|
756
771
|
}
|
|
757
772
|
async clearInput({ testId: t }) {
|
|
758
|
-
await new
|
|
773
|
+
await new L(this.page).clearInput({ testId: t });
|
|
759
774
|
}
|
|
760
775
|
async clickOnXButton({ testId: t }) {
|
|
761
|
-
await this.page.getByTestId(n(t,
|
|
776
|
+
await this.page.getByTestId(n(t, N.CLEAR)).locator(".icon-name--x-circle").click();
|
|
762
777
|
}
|
|
763
778
|
isDisabled({ testId: t }) {
|
|
764
|
-
return new
|
|
779
|
+
return new L(this.page).isDisabled({ testId: t });
|
|
765
780
|
}
|
|
766
781
|
getSearchPlaceholder({ testId: t }) {
|
|
767
|
-
return new
|
|
782
|
+
return new L(this.page).getPlaceholderText({ testId: t });
|
|
768
783
|
}
|
|
769
784
|
getSearchInputValue({ testId: t }) {
|
|
770
|
-
return new
|
|
785
|
+
return new L(this.page).getInputsFieldText({ testId: t });
|
|
771
786
|
}
|
|
772
787
|
}
|
|
773
|
-
class
|
|
788
|
+
class j {
|
|
774
789
|
constructor(t) {
|
|
775
|
-
|
|
790
|
+
c(this, "page");
|
|
776
791
|
this.page = t;
|
|
777
792
|
}
|
|
778
793
|
async waitForComponent({ testId: t }) {
|
|
779
|
-
const e = `[data-testid='${t}-${
|
|
794
|
+
const e = `[data-testid='${t}-${_.TEXT}']`;
|
|
780
795
|
await this.page.waitForSelector(e);
|
|
781
796
|
}
|
|
782
797
|
getInlineCopyText({ testId: t }) {
|
|
783
|
-
return this.page.getByTestId(`${t}-${
|
|
798
|
+
return this.page.getByTestId(`${t}-${_.TEXT}`).textContent();
|
|
784
799
|
}
|
|
785
800
|
}
|
|
786
|
-
class
|
|
801
|
+
class gt {
|
|
787
802
|
constructor(t) {
|
|
788
|
-
|
|
803
|
+
c(this, "page");
|
|
789
804
|
this.page = t;
|
|
790
805
|
}
|
|
791
806
|
async waitForComponent({ testId: t }) {
|
|
792
|
-
const e = `[data-testid='${t}-${
|
|
807
|
+
const e = `[data-testid='${t}-${b.TITLE}']`;
|
|
793
808
|
await this.page.waitForSelector(e);
|
|
794
809
|
}
|
|
795
810
|
getHeaderTitle({ testId: t }) {
|
|
796
|
-
return this.page.getByTestId(`${t}-${
|
|
811
|
+
return this.page.getByTestId(`${t}-${b.TITLE}`).textContent();
|
|
797
812
|
}
|
|
798
813
|
getInlineCopyText({ testId: t }) {
|
|
799
|
-
return new
|
|
814
|
+
return new j(this.page).getInlineCopyText({
|
|
800
815
|
testId: t
|
|
801
816
|
});
|
|
802
817
|
}
|
|
@@ -804,79 +819,79 @@ class ct {
|
|
|
804
819
|
testId: t,
|
|
805
820
|
iconName: e
|
|
806
821
|
}) {
|
|
807
|
-
return await this.page.getByTestId(`${t}-${
|
|
822
|
+
return await this.page.getByTestId(`${t}-${b.APP_PLATFORM}`).getAttribute("data-platform") === e;
|
|
808
823
|
}
|
|
809
824
|
}
|
|
810
|
-
class
|
|
825
|
+
class Tt {
|
|
811
826
|
constructor(t) {
|
|
812
|
-
|
|
827
|
+
c(this, "page");
|
|
813
828
|
this.page = t;
|
|
814
829
|
}
|
|
815
830
|
async waitForComponent({ testId: t }) {
|
|
816
|
-
const e = `[data-testid='${t}-${
|
|
831
|
+
const e = `[data-testid='${t}-${d.WRAPPER}']`;
|
|
817
832
|
await this.page.waitForSelector(e);
|
|
818
833
|
}
|
|
819
834
|
getAlertText({ testId: t }) {
|
|
820
|
-
return this.page.getByTestId(n(t,
|
|
835
|
+
return this.page.getByTestId(n(t, d.MESSAGE)).textContent();
|
|
821
836
|
}
|
|
822
837
|
getAlertTitle({ testId: t }) {
|
|
823
|
-
return this.page.getByTestId(n(t,
|
|
838
|
+
return this.page.getByTestId(n(t, d.TITLE)).textContent();
|
|
824
839
|
}
|
|
825
840
|
async clickOnActionButton({ testId: t }) {
|
|
826
841
|
await this.page.click(
|
|
827
|
-
n(t,
|
|
842
|
+
n(t, d.ACTION_BUTTON)
|
|
828
843
|
);
|
|
829
844
|
}
|
|
830
845
|
getActionButtonText({ testId: t }) {
|
|
831
|
-
return this.page.getByTestId(n(t,
|
|
846
|
+
return this.page.getByTestId(n(t, d.ACTION_BUTTON)).textContent();
|
|
832
847
|
}
|
|
833
848
|
async closeAlert({ testId: t }) {
|
|
834
|
-
await this.page.getByTestId(n(t,
|
|
849
|
+
await this.page.getByTestId(n(t, d.CLOSE_BUTTON)).click();
|
|
835
850
|
}
|
|
836
851
|
async isAlertVisible({ testId: t }) {
|
|
837
|
-
return await this.page.getByTestId(n(t,
|
|
852
|
+
return await this.page.getByTestId(n(t, d.WRAPPER)).count() > 0;
|
|
838
853
|
}
|
|
839
854
|
getAlertIconType({ testId: t }) {
|
|
840
|
-
return this.page.getByTestId(n(t,
|
|
855
|
+
return this.page.getByTestId(n(t, d.WRAPPER)).getAttribute("class");
|
|
841
856
|
}
|
|
842
857
|
}
|
|
843
|
-
class
|
|
858
|
+
class q {
|
|
844
859
|
constructor(t) {
|
|
845
|
-
|
|
860
|
+
c(this, "page");
|
|
846
861
|
this.page = t;
|
|
847
862
|
}
|
|
848
863
|
async waitForComponent({ testId: t }) {
|
|
849
|
-
const e = `[data-testid='${t}-${
|
|
864
|
+
const e = `[data-testid='${t}-${C.FIELD}']`;
|
|
850
865
|
await this.page.waitForSelector(e);
|
|
851
866
|
}
|
|
852
867
|
async addInput({ testId: t, text: e }) {
|
|
853
|
-
await this.page.getByTestId(n(t,
|
|
868
|
+
await this.page.getByTestId(n(t, C.FIELD)).type(e);
|
|
854
869
|
}
|
|
855
870
|
async clearInput({ testId: t }) {
|
|
856
|
-
await this.page.getByTestId(n(t,
|
|
871
|
+
await this.page.getByTestId(n(t, C.FIELD)).clear();
|
|
857
872
|
}
|
|
858
873
|
getInput({ testId: t }) {
|
|
859
|
-
return this.page.getByTestId(n(t,
|
|
874
|
+
return this.page.getByTestId(n(t, C.FIELD)).inputValue();
|
|
860
875
|
}
|
|
861
876
|
getPlaceholderText({ testId: t }) {
|
|
862
|
-
return this.page.getByTestId(n(t,
|
|
877
|
+
return this.page.getByTestId(n(t, C.FIELD)).getAttribute("placeholder");
|
|
863
878
|
}
|
|
864
879
|
isDisabled({ testId: t }) {
|
|
865
|
-
return this.page.getByTestId(n(t,
|
|
880
|
+
return this.page.getByTestId(n(t, C.FIELD)).isDisabled();
|
|
866
881
|
}
|
|
867
882
|
}
|
|
868
|
-
class
|
|
883
|
+
class ht extends q {
|
|
869
884
|
getLabelText({ testId: t }) {
|
|
870
|
-
return this.page.getByTestId(n(t,
|
|
885
|
+
return this.page.getByTestId(n(t, m.TEXT)).textContent();
|
|
871
886
|
}
|
|
872
887
|
hasFieldHelpText({ testId: t }) {
|
|
873
|
-
return this.page.getByTestId(n(t,
|
|
888
|
+
return this.page.getByTestId(n(t, w.CONTAINER)).isVisible();
|
|
874
889
|
}
|
|
875
890
|
getFieldHelpText({ testId: t }) {
|
|
876
|
-
return this.page.getByTestId(n(t,
|
|
891
|
+
return this.page.getByTestId(n(t, w.CONTAINER)).textContent();
|
|
877
892
|
}
|
|
878
893
|
}
|
|
879
|
-
class
|
|
894
|
+
class ut extends X {
|
|
880
895
|
constructor(t) {
|
|
881
896
|
super(t);
|
|
882
897
|
}
|
|
@@ -902,10 +917,10 @@ class gt extends f {
|
|
|
902
917
|
return this.page.getByTestId(n(t, s.BUTTON_CONTENT)).textContent();
|
|
903
918
|
}
|
|
904
919
|
async searchForItem({ testId: t, searchTerm: e }) {
|
|
905
|
-
return await this.openDropdownComponent({ testId: t }), await this.page.getByTestId(n(t,
|
|
920
|
+
return await this.openDropdownComponent({ testId: t }), await this.page.getByTestId(n(t, r.FIELD)).fill(e), this.page.getByTestId(n(t, s.LIST_CONTAINER)).locator("ul > li span").first().textContent();
|
|
906
921
|
}
|
|
907
922
|
async isErrorText({ testId: t }) {
|
|
908
|
-
return await this.page.getByTestId(n(t,
|
|
923
|
+
return await this.page.getByTestId(n(t, w.TEXT)).count() > 0;
|
|
909
924
|
}
|
|
910
925
|
async isDisabled({ testId: t }) {
|
|
911
926
|
return (await this.page.getByTestId(n(t, s.TRIGGER)).locator(".button__container--disabled")).isVisible();
|
|
@@ -941,9 +956,9 @@ class gt extends f {
|
|
|
941
956
|
shouldExpand: o = !1
|
|
942
957
|
}) {
|
|
943
958
|
await this.openDropdownComponent({ testId: t }), o && await this.expandTreeNode({ testId: t, nodeName: e });
|
|
944
|
-
const
|
|
945
|
-
if (await
|
|
946
|
-
await
|
|
959
|
+
const i = this.page.getByTestId(n(t, s.LIST_CONTAINER)).locator(`text=${e}`);
|
|
960
|
+
if (await i.isVisible())
|
|
961
|
+
await i.click();
|
|
947
962
|
else
|
|
948
963
|
throw new Error(`Option with text "${e}" not found in the dropdown.`);
|
|
949
964
|
}
|
|
@@ -961,55 +976,155 @@ class gt extends f {
|
|
|
961
976
|
await this.clickOnApply({ testId: t });
|
|
962
977
|
}
|
|
963
978
|
}
|
|
964
|
-
|
|
979
|
+
const z = ".sortable-item";
|
|
980
|
+
class dt {
|
|
965
981
|
constructor(t) {
|
|
966
|
-
|
|
982
|
+
c(this, "page");
|
|
967
983
|
this.page = t;
|
|
968
984
|
}
|
|
969
985
|
async waitForComponent({ testId: t }) {
|
|
970
|
-
const e = `[data-testid='${t}-${
|
|
986
|
+
const e = `[data-testid='${t}-${T.CONTAINER}']`;
|
|
971
987
|
await this.page.waitForSelector(e);
|
|
972
988
|
}
|
|
973
989
|
async isComponentLoaded(t) {
|
|
974
|
-
const e = `[data-testid='${t}-${
|
|
990
|
+
const e = `[data-testid='${t}-${T.CONTAINER}']`;
|
|
975
991
|
return this.page.isVisible(e);
|
|
976
992
|
}
|
|
977
993
|
async getItems(t) {
|
|
978
994
|
return this.page.getByTestId(n(t, "sortable-list-item")).allTextContents();
|
|
979
995
|
}
|
|
980
996
|
async sortItem(t, e, o) {
|
|
981
|
-
const
|
|
997
|
+
const i = await this.page.getByTestId(
|
|
982
998
|
n(t, "sortable-list-item")
|
|
983
|
-
),
|
|
984
|
-
await
|
|
999
|
+
), l = i.nth(e), h = i.nth(o);
|
|
1000
|
+
await l.dragTo(h);
|
|
985
1001
|
}
|
|
986
1002
|
async verifyOrder(t, e) {
|
|
987
|
-
return (await this.getItems(t)).every((
|
|
1003
|
+
return (await this.getItems(t)).every((i, l) => i === e[l]);
|
|
1004
|
+
}
|
|
1005
|
+
async getListItemLocator({ testId: t, item: e, modifier: o }) {
|
|
1006
|
+
return this.page.getByTestId(n(t, o)).locator(z, {
|
|
1007
|
+
hasText: e
|
|
1008
|
+
});
|
|
1009
|
+
}
|
|
1010
|
+
async selectItem({ testId: t, item: e, isLockedItem: o }) {
|
|
1011
|
+
const i = o ? T.LOCKED_LIST : T.DRAGGABLE_LIST;
|
|
1012
|
+
await (await this.getListItemLocator({
|
|
1013
|
+
testId: t,
|
|
1014
|
+
item: e,
|
|
1015
|
+
modifier: i
|
|
1016
|
+
})).click();
|
|
1017
|
+
}
|
|
1018
|
+
async isItemSelected(t) {
|
|
1019
|
+
return await this.page.locator(".sortable-item--selected", { hasText: t }).count() > 0;
|
|
1020
|
+
}
|
|
1021
|
+
async expandItem({ testId: t, item: e, isLockedItem: o }) {
|
|
1022
|
+
const i = o ? T.LOCKED_LIST : T.DRAGGABLE_LIST;
|
|
1023
|
+
await (await this.getListItemLocator({
|
|
1024
|
+
testId: t,
|
|
1025
|
+
item: e,
|
|
1026
|
+
modifier: i
|
|
1027
|
+
})).locator(".expand-icon").click();
|
|
1028
|
+
}
|
|
1029
|
+
async selectChildItem({
|
|
1030
|
+
testId: t,
|
|
1031
|
+
item: e,
|
|
1032
|
+
childItem: o,
|
|
1033
|
+
isLockedItem: i
|
|
1034
|
+
}) {
|
|
1035
|
+
await this.expandItem({
|
|
1036
|
+
testId: t,
|
|
1037
|
+
item: e,
|
|
1038
|
+
isLockedItem: i
|
|
1039
|
+
}), await this.page.locator("ul li span", {
|
|
1040
|
+
hasText: o
|
|
1041
|
+
}).click();
|
|
1042
|
+
}
|
|
1043
|
+
async isListOpened({ testId: t, item: e, isLockedItem: o }) {
|
|
1044
|
+
const i = o ? T.LOCKED_LIST : T.DRAGGABLE_LIST;
|
|
1045
|
+
return await (await this.getListItemLocator({
|
|
1046
|
+
testId: t,
|
|
1047
|
+
item: e,
|
|
1048
|
+
modifier: i
|
|
1049
|
+
})).locator(".child-list ul").count() > 0;
|
|
1050
|
+
}
|
|
1051
|
+
async isChildItemSelected(t) {
|
|
1052
|
+
return await this.page.locator("ul li span", { hasText: t }).count() > 0;
|
|
1053
|
+
}
|
|
1054
|
+
async openItemMenu({ testId: t, item: e, isLockedItem: o }) {
|
|
1055
|
+
const i = o ? T.LOCKED_LIST : T.DRAGGABLE_LIST;
|
|
1056
|
+
await (await this.getListItemLocator({
|
|
1057
|
+
testId: t,
|
|
1058
|
+
item: e,
|
|
1059
|
+
modifier: i
|
|
1060
|
+
})).locator(".item__menu button").click();
|
|
1061
|
+
}
|
|
1062
|
+
async selectMenuItem({
|
|
1063
|
+
testId: t,
|
|
1064
|
+
item: e,
|
|
1065
|
+
isLockedItem: o,
|
|
1066
|
+
menuItem: i
|
|
1067
|
+
}) {
|
|
1068
|
+
await this.openItemMenu({
|
|
1069
|
+
testId: t,
|
|
1070
|
+
item: e,
|
|
1071
|
+
isLockedItem: o
|
|
1072
|
+
});
|
|
1073
|
+
const l = this.page.locator(".dropdown-list-wrapper");
|
|
1074
|
+
await l.locator("ul.list li", { hasText: i }).click(), await l.waitFor({ state: "detached" });
|
|
1075
|
+
}
|
|
1076
|
+
async isMenuOpened() {
|
|
1077
|
+
return await this.page.locator(".dropdown-list-wrapper").count() > 0;
|
|
1078
|
+
}
|
|
1079
|
+
async dragAndDrop({ testId: t, item: e, isLockedItem: o }) {
|
|
1080
|
+
const i = o ? T.LOCKED_LIST : T.DRAGGABLE_LIST, h = await (await this.getListItemLocator({
|
|
1081
|
+
testId: t,
|
|
1082
|
+
item: e,
|
|
1083
|
+
modifier: i
|
|
1084
|
+
})).locator(".item.drag-allowed").first().boundingBox();
|
|
1085
|
+
if (h) {
|
|
1086
|
+
const k = h.x, D = h.y;
|
|
1087
|
+
await this.page.mouse.move(k, D), await this.page.mouse.down(), await this.page.mouse.move(k + 20, D - 20), await this.page.mouse.up();
|
|
1088
|
+
}
|
|
1089
|
+
}
|
|
1090
|
+
async getListOrder() {
|
|
1091
|
+
return (await this.page.locator(".sortable-list-container .item__text span").allInnerTexts()).reduce((e, o, i) => (e[i + 1] = o, e), {});
|
|
1092
|
+
}
|
|
1093
|
+
async searchForItem({ testId: t, searchTerm: e }) {
|
|
1094
|
+
return await this.page.getByTestId(n(t, r.FIELD)).fill(e), this.page.getByTestId(n(t, T.CONTAINER)).locator("ul > li span").first().textContent();
|
|
1095
|
+
}
|
|
1096
|
+
// returns array of booleans according to the search results in each group
|
|
1097
|
+
async verifySearchResultDisplayed({ testId: t, item: e }) {
|
|
1098
|
+
const o = [], i = await this.page.getByTestId(n(t, T.CONTAINER)).all();
|
|
1099
|
+
let l;
|
|
1100
|
+
for (const h of i)
|
|
1101
|
+
l = await h.locator(".child-list span", { hasText: e }).count(), o.push(l > 0);
|
|
1102
|
+
return o;
|
|
988
1103
|
}
|
|
989
1104
|
}
|
|
990
1105
|
export {
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
|
|
994
|
-
|
|
995
|
-
|
|
996
|
-
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1106
|
+
Tt as AlertComponent,
|
|
1107
|
+
gt as AppHeaderComponent,
|
|
1108
|
+
Q as BannerComponent,
|
|
1109
|
+
K as ButtonComponent,
|
|
1110
|
+
Z as ComponentBasePage,
|
|
1111
|
+
M as DialogComponent,
|
|
1112
|
+
X as DropdownComponent,
|
|
1113
|
+
tt as DropdownComponentV3,
|
|
1114
|
+
F as FieldHelpTextComponent,
|
|
1000
1115
|
A as FieldLabelComponent,
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1006
|
-
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
|
|
1011
|
-
|
|
1012
|
-
|
|
1013
|
-
|
|
1014
|
-
|
|
1116
|
+
lt as FormCardComponent,
|
|
1117
|
+
ct as FormRowComponent,
|
|
1118
|
+
et as IncludeExcludeComponent,
|
|
1119
|
+
j as InlineCopyComponent,
|
|
1120
|
+
at as InputsComponent,
|
|
1121
|
+
rt as MultiBarComponent,
|
|
1122
|
+
pt as SearchComponent,
|
|
1123
|
+
st as SnackbarComponent,
|
|
1124
|
+
dt as SortableListComponent,
|
|
1125
|
+
it as TableComponent,
|
|
1126
|
+
nt as TabsComponent,
|
|
1127
|
+
ht as TextAreaComponent,
|
|
1128
|
+
ot as TooltipComponent,
|
|
1129
|
+
ut as TreeDropdownComponent
|
|
1015
1130
|
};
|