dimsum-e2e-tests 3.49.0-rc.4 → 3.50.0-next.2
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/CHANGELOG.md +321 -227
- package/ds-breadcrumb/DSBreadcrumb.visual.spec.js +13 -18
- package/ds-button-v3/DSButtonV3CO.js +0 -4
- package/ds-controlled-form/ds-combobox/DSCombobox.func.spec.js +0 -1
- package/ds-controlled-form/ds-combobox/DSCombobox.smoke.spec.js +56 -4
- package/ds-controlled-form/ds-combobox/DSComboboxCO.js +9 -0
- package/ds-controlled-form/ds-combobox/creatable/DSCombobox.keyboard-creatable.func.spec.js +0 -3
- package/ds-controlled-form/ds-combobox/inline/DSCombobox.inline.axe-core.spec.js +1 -0
- package/ds-controlled-form/ds-combobox/inline/DSCombobox.inline.keyboard.func.spec.js +0 -3
- package/ds-controlled-form/ds-combobox/multi-select/DSCombobox.keyboard-multi-select.func.spec.js +68 -5
- package/ds-controlled-form/ds-combobox/multi-select/DSCombobox.mouse-touch-multi-select.func.spec.js +58 -0
- package/ds-controlled-form/ds-combobox/multi-select/DSCombobox.multi.visual.spec.js +16 -0
- package/ds-controlled-form/ds-combobox/multi-select/DSCombobox.ten-thousand-options.func.spec.js +22 -2
- package/ds-controlled-form/ds-combobox/single-select/DSCombobox.keyboard-single-select.func.spec.js +0 -3
- package/ds-controlled-form/ds-controlled-date-range-picker/DSControlledDateRangePicker.DateInput.visual.spec.js +57 -0
- package/ds-controlled-form/ds-controlled-date-range-picker/DSControlledDateRangePickerCO.js +2 -54
- package/ds-controlled-form/ds-controlled-inputgroup/DSControlledInputGroupCO.js +0 -4
- package/ds-controlled-form/ds-controlled-inputgroup/combobox/DSControlledInputGroup.combobox.axe-core.func.spec.js +1 -1
- package/ds-data-table-async/DSDataTable.smoke.spec.js +0 -4
- package/ds-data-table-async/filters/DSDataTable.filters-creatable.func.spec.js +0 -4
- package/ds-data-table-async/select/DSDataTable.select.axe-core.func.spec.js +0 -2
- package/ds-form-combobox-multi/DSComboboxMultiCO.js +9 -0
- package/ds-form-combobox-multi/aria-disabled/DSComboboxMulti.aria-disabled.visual.spec.js +10 -0
- package/ds-form-combobox-single/DSComboboxSingleCO.js +9 -0
- package/ds-form-layout-blocks/form-layout-block-item/DSFormLayoutBlockItemCO.js +0 -4
- package/ds-menu-button/DSMenuButton.axe-core.func.spec.js +66 -0
- package/ds-menu-button/DSMenuButtonCO.js +5 -5
- package/ds-menu-button/{activable/DSMenuButton.activableMenuItem.keyboardnav.func.spec.js → basic/DSMenuButton.activableMenuItem.func.spec.js} +26 -1
- package/ds-menu-button/{multiselect/DSMenuButton.multiSelectItem.keyboardnav.func.spec.js → basic/DSMenuButton.multiSelectItem.func.spec.js} +29 -0
- package/ds-menu-button/{singleSelect/DSMenuButton.singleSelectItem.keyboardnav.func.spec.js → basic/DSMenuButton.singleSelectItem.func.spec.js} +42 -11
- package/ds-menu-button/{submenu/DSMenuButton.subMenuItem.keyboardnav.func.spec.js → basic/DSMenuButton.subMenuItem.func.spec.js} +38 -1
- package/ds-pills-v2/DSPills.axe-core.func.spec.js +2 -2
- package/ds-pills-v2/DSPills.visual.spec.js +1 -1
- package/ds-pills-v2/DSPillsV2CO.js +1 -15
- package/ds-shuttle-v2/DSShuttleV2CO.js +4 -2
- package/ds-shuttle-v2/basic/DSShuttleV2.keyboard.func.spec.js +66 -46
- package/ds-shuttle-v2/drillingdown/DSShuttleV2.drilldown.kb.func.spec.js +5 -3
- package/ds-shuttle-v2/filtering/DSShuttleV2.filter.kb.func.spec.js +7 -1
- package/ds-shuttle-v2/globalcheckbox/DSShuttleV2.globalcheckbox.kb.func.spec.js +2 -0
- package/ds-shuttle-v2/items/DSShuttleV2.items.kb.func.spec.js +2 -0
- package/ds-toggle/DSToggle.func.spec.js +18 -21
- package/ds-toggle/DSToggle.visual.spec.js +12 -36
- package/package.json +119 -119
- package/ds-controlled-form/ds-controlled-date-range-picker/DSControlledDateRangePicker.axe-core.spec.js +0 -85
- package/ds-controlled-form/ds-controlled-date-range-picker/DSControlledDateRangePicker.functional.spec.js +0 -242
- package/ds-controlled-form/ds-controlled-date-range-picker/DSControlledDateRangePicker.visual.spec.js +0 -115
- package/ds-menu-button/activable/DSMenuButton.activableMenuItem.func.spec.js +0 -32
- package/ds-menu-button/multiselect/DSMenuButton.axe-core.multiselect.func.spec.js +0 -28
- package/ds-menu-button/multiselect/DSMenuButton.multiSelectItem.func.spec.js +0 -34
- package/ds-menu-button/singleSelect/DSMenuButton.axe-core.singleSelect.func.spec.js +0 -28
- package/ds-menu-button/singleSelect/DSMenuButton.singleSelectItem.func.spec.js +0 -39
- package/ds-menu-button/submenu/DSMenuButton.axe-core.subMenu.func.spec.js +0 -20
- package/ds-menu-button/submenu/DSMenuButton.subMenuItem.func.spec.js +0 -42
- package/ds-pills-v2/selection/DSPills.axe-core.func.spec.js +0 -77
- package/ds-pills-v2/selection/DSPills.func.spec.js +0 -155
- package/ds-pills-v2/selection/DSPills.visual.spec.js +0 -72
|
@@ -132,14 +132,16 @@ export default class DSShuttleV2CO extends PageObject {
|
|
|
132
132
|
|
|
133
133
|
static getCheckboxByIndex = async (index = 0) => $$(`[data-testid="ds-checkbox"]`)[index];
|
|
134
134
|
|
|
135
|
-
static getBreadcrumbItemContByIndex = async (index = 0) => $$(`[data-testid="breadcrumb-item-content"]`)[index];
|
|
136
|
-
|
|
137
135
|
static getBreadcrumbByIndex = async (index = 0) => $$(`[data-testid="breadcrumb-item-container"]`)[index];
|
|
138
136
|
|
|
139
137
|
static getBreadcrumbs = async () => $$(`[data-testid="breadcrumb-item-container"]`);
|
|
140
138
|
|
|
139
|
+
static getFocuseableByBreadcrumb = async (breadcrumb) => breadcrumb.$(`[data-testid="ds-typography-element"]`);
|
|
140
|
+
|
|
141
141
|
static getSubtitleByItem = async (item) => item.$$(`p`)[1];
|
|
142
142
|
|
|
143
|
+
static getTypographyByItem = async (item) => item.$(`[data-testid="ds-typography-element"]`);
|
|
144
|
+
|
|
143
145
|
static getActionButtonByItemAndIndex = async (item, index = 0) =>
|
|
144
146
|
item.$$(`[data-testid=${DSShuttleV2DataTestIds.ITEM_ACTION_BTN}]`)[index];
|
|
145
147
|
|
|
@@ -9,29 +9,35 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
9
9
|
const errorOnGo = await DSShuttleV2CO.filterURL.go();
|
|
10
10
|
if (errorOnGo) throw errorOnGo;
|
|
11
11
|
});
|
|
12
|
-
it('01: should tab and focus the
|
|
12
|
+
it('01: should tab and focus the breadcrumb', async () => {
|
|
13
|
+
await browser.keys(Key.Tab);
|
|
14
|
+
const breadCrumb = await DSShuttleV2CO.getBreadcrumbByIndex(0);
|
|
15
|
+
const breadcrumbFocuseable = await DSShuttleV2CO.getFocuseableByBreadcrumb(breadCrumb);
|
|
16
|
+
await expect(breadcrumbFocuseable).toBeFocused();
|
|
17
|
+
});
|
|
18
|
+
it('02: should tab and focus the filter icon', async () => {
|
|
13
19
|
await browser.keys(Key.Tab);
|
|
14
20
|
const sourceFilterBtn = await DSShuttleV2CO.getHeaderSearchIcon(0);
|
|
15
21
|
await expect(sourceFilterBtn).toBeFocused();
|
|
16
22
|
});
|
|
17
|
-
it('
|
|
23
|
+
it('03: should tab and focus the select/deselect all checkbox', async () => {
|
|
18
24
|
await browser.keys(Key.Tab);
|
|
19
25
|
const sourcePanelCheckbox = await DSShuttleV2CO.getCheckboxByIndex(0);
|
|
20
26
|
await expect(sourcePanelCheckbox).toBeFocused();
|
|
21
27
|
});
|
|
22
|
-
it('
|
|
28
|
+
it('04: should tab and focus the source panel', async () => {
|
|
23
29
|
await browser.keys(Key.Tab);
|
|
24
30
|
const sourcePanel = await DSShuttleV2CO.getListWrapperMid(0);
|
|
25
31
|
await expect(sourcePanel).toBeFocused();
|
|
26
32
|
});
|
|
27
|
-
it('
|
|
33
|
+
it('05: should select first item with arrowKeys', async () => {
|
|
28
34
|
await browser.keys(Key.ArrowDown);
|
|
29
35
|
const firstItem = await DSShuttleV2CO.getItemCheckboxByItem(await DSShuttleV2CO.getItemFromSourceByIndex(0));
|
|
30
36
|
const isFirstItemFocused = await firstItem.getAttribute('tabindex');
|
|
31
37
|
await expect(isFirstItemFocused).toEqual('0'); // 0 = true for pseudofocus
|
|
32
38
|
await expect(firstItem).toBeFocused();
|
|
33
39
|
});
|
|
34
|
-
it('
|
|
40
|
+
it('06: should Shift+Tab to focus the panel again and select last item with arrowKeys', async () => {
|
|
35
41
|
await browser.keys([Key.Shift, Key.Tab]);
|
|
36
42
|
await browser.keys(Key.ArrowUp);
|
|
37
43
|
const firstItem = await DSShuttleV2CO.getItemCheckboxByIndex(9);
|
|
@@ -39,56 +45,64 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
39
45
|
await expect(isFirstItemFocused).toEqual('0'); // 0 = true for pseudofocus
|
|
40
46
|
await expect(firstItem).toBeFocused();
|
|
41
47
|
});
|
|
42
|
-
it('
|
|
48
|
+
it('07: should tab and focus the breadcrumb from destination panel', async () => {
|
|
43
49
|
await browser.keys(Key.Tab);
|
|
44
|
-
const
|
|
45
|
-
await
|
|
50
|
+
const breadCrumb = await DSShuttleV2CO.getBreadcrumbByIndex(1);
|
|
51
|
+
const breadcrumbFocuseable = await DSShuttleV2CO.getFocuseableByBreadcrumb(breadCrumb);
|
|
52
|
+
await expect(breadcrumbFocuseable).toBeFocused();
|
|
46
53
|
});
|
|
47
54
|
});
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
85
|
-
|
|
55
|
+
|
|
56
|
+
describe('PUI-9799 - Shuttle V2, TabStops with BAB and LoadMore -Func.', () => {
|
|
57
|
+
before(async () => {
|
|
58
|
+
const errorOnGo = await DSShuttleV2CO.loadMoreURL.go();
|
|
59
|
+
if (errorOnGo) throw errorOnGo;
|
|
60
|
+
});
|
|
61
|
+
it('01: display the BAB and return focus to the breadcrumb to follow normal flow', async () => {
|
|
62
|
+
const testItem = await DSShuttleV2CO.getItemWrapper(2);
|
|
63
|
+
await testItem.click();
|
|
64
|
+
const breadCrumb = await DSShuttleV2CO.getBreadcrumbByIndex(0);
|
|
65
|
+
await breadCrumb.click();
|
|
66
|
+
const breadcrumbFocuseable = await DSShuttleV2CO.getFocuseableByBreadcrumb(breadCrumb);
|
|
67
|
+
const BAB = await DSShuttleV2CO.getMoveMultipleButton();
|
|
68
|
+
await expect(BAB).toBeDisplayed();
|
|
69
|
+
await expect(breadcrumbFocuseable).toBeFocused();
|
|
70
|
+
});
|
|
71
|
+
it('02: should tab and focus the select/deselect all checkbox', async () => {
|
|
72
|
+
await browser.keys(Key.Tab);
|
|
73
|
+
const sourcePanelCheckbox = await DSShuttleV2CO.getCheckboxByIndex(0);
|
|
74
|
+
await expect(sourcePanelCheckbox).toBeFocused();
|
|
75
|
+
});
|
|
76
|
+
it('03: should tab and focus the source panel', async () => {
|
|
77
|
+
await browser.keys(Key.Tab);
|
|
78
|
+
const sourcePanel = await DSShuttleV2CO.getListWrapperMid(0);
|
|
79
|
+
await expect(sourcePanel).toBeFocused();
|
|
80
|
+
});
|
|
81
|
+
it('04: should tab and focus the BAB', async () => {
|
|
82
|
+
await browser.keys(Key.Tab);
|
|
83
|
+
const BAB = await DSShuttleV2CO.getMoveMultipleButton(0);
|
|
84
|
+
await expect(BAB).toBeFocused();
|
|
85
|
+
});
|
|
86
|
+
it('05: should tab and focus the loadmore', async () => {
|
|
87
|
+
await browser.keys(Key.Tab);
|
|
88
|
+
const loadMore = await DSShuttleV2CO.getListBottomLoadMoreBtn(0);
|
|
89
|
+
await expect(loadMore).toBeFocused();
|
|
90
|
+
});
|
|
91
|
+
it('06: should tab and focus the breadcrumb from destination panel', async () => {
|
|
92
|
+
await browser.keys(Key.Tab);
|
|
93
|
+
const breadCrumb = await DSShuttleV2CO.getBreadcrumbByIndex(1);
|
|
94
|
+
const breadcrumbFocuseable = await DSShuttleV2CO.getFocuseableByBreadcrumb(breadCrumb);
|
|
95
|
+
await expect(breadcrumbFocuseable).toBeFocused();
|
|
96
|
+
});
|
|
97
|
+
});
|
|
98
|
+
|
|
86
99
|
describe('PUI-9815 - Shuttle V2, Range selection -Func.', () => {
|
|
87
100
|
before(async () => {
|
|
88
101
|
const errorOnGo = await DSShuttleV2CO.basicURL.go();
|
|
89
102
|
if (errorOnGo) throw errorOnGo;
|
|
90
103
|
});
|
|
91
104
|
it('01: should select four items pressing space only two times (using shift for range select)', async () => {
|
|
105
|
+
await browser.keys(Key.Tab);
|
|
92
106
|
await browser.keys(Key.Tab);
|
|
93
107
|
await browser.keys(Key.Tab);
|
|
94
108
|
await browser.keys(Key.ArrowDown);
|
|
@@ -139,6 +153,8 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
139
153
|
await browser.keys(Key.Tab);
|
|
140
154
|
await browser.keys(Key.Tab);
|
|
141
155
|
await browser.keys(Key.Tab);
|
|
156
|
+
await browser.keys(Key.Tab);
|
|
157
|
+
await browser.keys(Key.Tab);
|
|
142
158
|
await browser.keys(Key.ArrowDown);
|
|
143
159
|
await browser.keys(Key.Space);
|
|
144
160
|
const bab = await DSShuttleV2CO.getMoveMultipleButton();
|
|
@@ -159,6 +175,7 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
159
175
|
await expect(testItem2OnSource).toBe('Destination 0.3');
|
|
160
176
|
});
|
|
161
177
|
it('03: should bulk move items from source to destination', async () => {
|
|
178
|
+
await browser.keys([Key.Shift, Key.Tab]);
|
|
162
179
|
await browser.keys([Key.Shift, Key.Tab]);
|
|
163
180
|
await browser.keys([Key.Shift, Key.Tab]);
|
|
164
181
|
await browser.keys(Key.ArrowDown);
|
|
@@ -184,6 +201,7 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
184
201
|
if (errorOnGo) throw errorOnGo;
|
|
185
202
|
});
|
|
186
203
|
it('01: should DND first item to fourth position (source)', async () => {
|
|
204
|
+
await browser.keys(Key.Tab);
|
|
187
205
|
await browser.keys(Key.Tab);
|
|
188
206
|
await browser.keys(Key.Tab);
|
|
189
207
|
await browser.keys(Key.ArrowDown);
|
|
@@ -206,6 +224,7 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
206
224
|
if (errorOnGo) throw errorOnGo;
|
|
207
225
|
});
|
|
208
226
|
it('01: should display tooltip on hover of a truncated item', async () => {
|
|
227
|
+
await browser.keys(Key.Tab);
|
|
209
228
|
await browser.keys(Key.Tab);
|
|
210
229
|
await browser.keys(Key.Tab);
|
|
211
230
|
await browser.keys(Key.ArrowDown);
|
|
@@ -223,6 +242,7 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
223
242
|
if (errorOnGo) throw errorOnGo;
|
|
224
243
|
});
|
|
225
244
|
it('01: should display focus BAB after selecting an item and arrow right', async () => {
|
|
245
|
+
await browser.keys(Key.Tab);
|
|
226
246
|
await browser.keys(Key.Tab);
|
|
227
247
|
await browser.keys(Key.Tab);
|
|
228
248
|
await browser.keys(Key.ArrowDown);
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
/* eslint-disable max-len */
|
|
2
1
|
/* eslint-disable no-unused-vars */
|
|
3
2
|
/* eslint-disable max-statements */
|
|
4
3
|
import { Key } from 'webdriverio';
|
|
@@ -11,6 +10,7 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
11
10
|
if (errorOnGo) throw errorOnGo;
|
|
12
11
|
});
|
|
13
12
|
it('01: should focus item', async () => {
|
|
13
|
+
await browser.keys(Key.Tab);
|
|
14
14
|
await browser.keys(Key.Tab);
|
|
15
15
|
await browser.keys(Key.Tab);
|
|
16
16
|
await browser.keys(Key.ArrowDown);
|
|
@@ -53,6 +53,7 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
53
53
|
if (errorOnGo) throw errorOnGo;
|
|
54
54
|
});
|
|
55
55
|
it('01: should add breadcrumbs with the items name while drilling down', async () => {
|
|
56
|
+
await browser.keys(Key.Tab);
|
|
56
57
|
await browser.keys(Key.Tab);
|
|
57
58
|
await browser.keys(Key.Tab);
|
|
58
59
|
await browser.keys(Key.ArrowDown);
|
|
@@ -93,8 +94,9 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
93
94
|
await browser.keys([Key.Shift, Key.Tab]);
|
|
94
95
|
await browser.keys([Key.Shift, Key.Tab]);
|
|
95
96
|
await browser.keys([Key.Shift, Key.Tab]);
|
|
97
|
+
await browser.keys([Key.Shift, Key.Tab]);
|
|
96
98
|
await browser.keys(Key.Enter);
|
|
97
|
-
const breadcrumbItem2 = await DSShuttleV2CO.
|
|
99
|
+
const breadcrumbItem2 = await DSShuttleV2CO.getFocuseableByBreadcrumb(await DSShuttleV2CO.getBreadcrumbByIndex(1));
|
|
98
100
|
const breadcrumbs = (await DSShuttleV2CO.getBreadcrumbs()).length;
|
|
99
101
|
await expect(breadcrumbItem2).toBeFocused();
|
|
100
102
|
await expect(breadcrumbs).toEqual(3);
|
|
@@ -102,7 +104,7 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
102
104
|
it('02: should focus first breadcrumb item after going up from second level with KB', async () => {
|
|
103
105
|
await browser.keys([Key.Shift, Key.Tab]);
|
|
104
106
|
await browser.keys(Key.Enter);
|
|
105
|
-
const breadcrumbItem1 = await DSShuttleV2CO.
|
|
107
|
+
const breadcrumbItem1 = await DSShuttleV2CO.getFocuseableByBreadcrumb(await DSShuttleV2CO.getBreadcrumbByIndex(0));
|
|
106
108
|
const breadcrumbs = (await DSShuttleV2CO.getBreadcrumbs()).length;
|
|
107
109
|
await expect(breadcrumbItem1).toBeFocused();
|
|
108
110
|
await expect(breadcrumbs).toEqual(2);
|
|
@@ -12,6 +12,7 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
12
12
|
await expect($('[data-testid="ds-shuttle-v2-area-search-bar"]')).not.toBeDisplayed();
|
|
13
13
|
});
|
|
14
14
|
it('02: should filter and find only one match at source panel', async () => {
|
|
15
|
+
await browser.keys(Key.Tab);
|
|
15
16
|
await browser.keys(Key.Tab);
|
|
16
17
|
await browser.keys(Key.Enter);
|
|
17
18
|
await browser.keys(Key.Tab);
|
|
@@ -26,6 +27,11 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
26
27
|
const testItem = await DSShuttleV2CO.getItemWrapper(0);
|
|
27
28
|
await browser.keys(Key.Tab);
|
|
28
29
|
await browser.keys(Key.Tab);
|
|
30
|
+
await browser.keys(Key.ArrowDown);
|
|
31
|
+
await browser.keys(Key.ArrowRight);
|
|
32
|
+
await browser.keys(Key.ArrowRight);
|
|
33
|
+
await browser.keys(Key.Enter);
|
|
34
|
+
await browser.keys(Key.Tab);
|
|
29
35
|
await browser.keys(Key.Tab);
|
|
30
36
|
await browser.keys(Key.Enter);
|
|
31
37
|
await browser.keys(Key.Tab);
|
|
@@ -34,7 +40,7 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
34
40
|
await expect(destinationItems).toBe(10);
|
|
35
41
|
});
|
|
36
42
|
it('04: should filter and find only one match at destination panel', async () => {
|
|
37
|
-
await type('0.3');
|
|
43
|
+
await type(' 0.3');
|
|
38
44
|
const destinationItems = (await DSShuttleV2CO.getItemsFromDestination()).length;
|
|
39
45
|
await expect(destinationItems).toBe(1);
|
|
40
46
|
const testItem = await (await DSShuttleV2CO.getItemFromDestinationByIndex(0)).getText();
|
|
@@ -18,6 +18,8 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
18
18
|
await browser.keys(Key.Tab);
|
|
19
19
|
await browser.keys(Key.Tab);
|
|
20
20
|
await browser.keys(Key.Tab);
|
|
21
|
+
await browser.keys(Key.Tab);
|
|
22
|
+
await browser.keys(Key.Tab);
|
|
21
23
|
await browser.keys(Key.ArrowDown);
|
|
22
24
|
await browser.keys(Key.Space);
|
|
23
25
|
const isChecked = await selectAllCheckbox.getAttribute('aria-checked');
|
|
@@ -8,6 +8,7 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
8
8
|
if (errorOnGo) throw errorOnGo;
|
|
9
9
|
});
|
|
10
10
|
it('01: should move an item to destination and display its ghost on that position', async () => {
|
|
11
|
+
await browser.keys(Key.Tab);
|
|
11
12
|
await browser.keys(Key.Tab);
|
|
12
13
|
await browser.keys(Key.Tab);
|
|
13
14
|
await browser.keys(Key.ArrowDown);
|
|
@@ -25,6 +26,7 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
25
26
|
await expect(destinationItems).toBe(11);
|
|
26
27
|
});
|
|
27
28
|
it('02: should return the item to its previous position', async () => {
|
|
29
|
+
await browser.keys(Key.Tab);
|
|
28
30
|
await browser.keys(Key.Tab);
|
|
29
31
|
await browser.keys(Key.Tab);
|
|
30
32
|
await browser.keys(Key.ArrowUp);
|
|
@@ -10,12 +10,12 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
10
10
|
if (errorOnGo) throw errorOnGo;
|
|
11
11
|
await (await DSToggleCO.getToggle()).waitForExist();
|
|
12
12
|
});
|
|
13
|
-
it('
|
|
13
|
+
it('should change state to ON', async () => {
|
|
14
14
|
await (await DSToggleCO.getToggle()).click();
|
|
15
15
|
const toggleState = await DSToggleCO.getToggleState('ON');
|
|
16
16
|
await expect(toggleState).toBeDisplayed();
|
|
17
17
|
});
|
|
18
|
-
it('
|
|
18
|
+
it('should change state to OFF', async () => {
|
|
19
19
|
await (await DSToggleCO.getToggle()).click();
|
|
20
20
|
const toggleState = await DSToggleCO.getToggleState('OFF');
|
|
21
21
|
await expect(toggleState).toBeDisplayed();
|
|
@@ -27,54 +27,51 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
27
27
|
if (errorOnGo) throw errorOnGo;
|
|
28
28
|
await (await DSToggleCO.getToggle()).waitForExist();
|
|
29
29
|
});
|
|
30
|
-
it('
|
|
30
|
+
it('toggle should be focused', async () => {
|
|
31
31
|
await browser.keys(Key.Tab);
|
|
32
32
|
const toggleComponent = await DSToggleCO.getToggleFocuseableByDataTestId('my-toggle');
|
|
33
33
|
await expect(toggleComponent).toBeFocused();
|
|
34
34
|
});
|
|
35
|
-
it('
|
|
35
|
+
it('should change state to ON (Enter)', async () => {
|
|
36
36
|
await browser.keys(Key.Enter);
|
|
37
37
|
const toggleState = await DSToggleCO.getToggleState('ON');
|
|
38
38
|
await expect(toggleState).toBeDisplayed();
|
|
39
39
|
});
|
|
40
|
-
it('
|
|
40
|
+
it('should change state to OFF (Space)', async () => {
|
|
41
41
|
await browser.keys(Key.Space);
|
|
42
42
|
const toggleState = await DSToggleCO.getToggleState('OFF');
|
|
43
43
|
await expect(toggleState).toBeDisplayed();
|
|
44
44
|
});
|
|
45
|
-
it('
|
|
45
|
+
it('should change state to ON (Space)', async () => {
|
|
46
46
|
await browser.keys(Key.Space);
|
|
47
47
|
const toggleState = await DSToggleCO.getToggleState('ON');
|
|
48
48
|
await expect(toggleState).toBeDisplayed();
|
|
49
49
|
});
|
|
50
50
|
});
|
|
51
|
-
|
|
52
51
|
describe('PUI-6761 - DSControlledToggle:: disabled state', () => {
|
|
53
52
|
before('loading page', async () => {
|
|
54
53
|
const errorOnGo = await DSToggleCO.disabled.go();
|
|
55
54
|
if (errorOnGo) throw errorOnGo;
|
|
56
55
|
await (await DSToggleCO.getToggle()).waitForExist();
|
|
57
56
|
});
|
|
58
|
-
it('
|
|
59
|
-
|
|
60
|
-
await
|
|
61
|
-
|
|
62
|
-
await expect(toggleState).toEqual('ON');
|
|
57
|
+
it('should not change state in disabled toggle', async () => {
|
|
58
|
+
await (await DSToggleCO.getToggle()).click();
|
|
59
|
+
const toggleState = await DSToggleCO.getToggleState('OFF');
|
|
60
|
+
await expect(toggleState).toBeDisplayed();
|
|
63
61
|
});
|
|
64
62
|
});
|
|
65
|
-
|
|
66
63
|
describe('PUI-6762 - DSControlledToggle:: read only state', () => {
|
|
67
64
|
before('loading page', async () => {
|
|
68
65
|
const errorOnGo = await DSToggleCO.readOnly.go();
|
|
69
66
|
if (errorOnGo) throw errorOnGo;
|
|
70
67
|
await (await DSToggleCO.getToggle()).waitForExist();
|
|
71
68
|
});
|
|
72
|
-
it('
|
|
69
|
+
it('should display tooltip in read only toggle (mouse over)', async () => {
|
|
73
70
|
await mouseOver(await DSToggleCO.getToggle(), 30, 10);
|
|
74
71
|
const tooltip = await DSToggleCO.getTooltip();
|
|
75
72
|
await expect(tooltip).toBeDisplayed();
|
|
76
73
|
});
|
|
77
|
-
it('
|
|
74
|
+
it('should display tooltip in read only toggle (keyboard focus)', async () => {
|
|
78
75
|
await mouseOver(await DSToggleCO.getToggle(), 300, 100);
|
|
79
76
|
await browser.keys(Key.Tab);
|
|
80
77
|
const toggleComponent = await DSToggleCO.getToggleFocuseable();
|
|
@@ -82,17 +79,17 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
82
79
|
await expect(toggleComponent).toBeFocused();
|
|
83
80
|
await expect(tooltip).toBeDisplayed();
|
|
84
81
|
});
|
|
85
|
-
it('
|
|
82
|
+
it('should not change state on [Enter] key press', async () => {
|
|
86
83
|
await browser.keys(Key.Enter);
|
|
87
84
|
const toggleState = await DSToggleCO.getToggleState('OFF');
|
|
88
85
|
await expect(toggleState).toBeDisplayed();
|
|
89
86
|
});
|
|
90
|
-
it('
|
|
87
|
+
it('should not change state on [Space] key press', async () => {
|
|
91
88
|
await browser.keys(Key.Space);
|
|
92
89
|
const toggleState = await DSToggleCO.getToggleState('OFF');
|
|
93
90
|
await expect(toggleState).toBeDisplayed();
|
|
94
91
|
});
|
|
95
|
-
it('
|
|
92
|
+
it('should not change state on click', async () => {
|
|
96
93
|
await (await DSToggleCO.getToggle()).click();
|
|
97
94
|
const toggleState = await DSToggleCO.getToggleState('OFF');
|
|
98
95
|
await expect(toggleState).toBeDisplayed();
|
|
@@ -104,17 +101,17 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
104
101
|
if (errorOnGo) throw errorOnGo;
|
|
105
102
|
await (await DSToggleCO.getToggle()).waitForExist();
|
|
106
103
|
});
|
|
107
|
-
it('
|
|
104
|
+
it('should tab through the basic toggles to the last basic toggle', async () => {
|
|
108
105
|
await tabStops(6);
|
|
109
106
|
const toggle = await DSToggleCO.getToggleFocuseableByIndex(4);
|
|
110
107
|
await expect(toggle).toBeFocused();
|
|
111
108
|
});
|
|
112
|
-
it('
|
|
109
|
+
it('should tab and skip all three disabled toggles to the first enabled toggle, next row', async () => {
|
|
113
110
|
await browser.keys(Key.Tab);
|
|
114
111
|
const toggle = await DSToggleCO.getToggleFocuseableByIndex(11);
|
|
115
112
|
await expect(toggle).toBeFocused();
|
|
116
113
|
});
|
|
117
|
-
it('
|
|
114
|
+
it('should tab through the readonly toggles to the last readonly toggle', async () => {
|
|
118
115
|
await tabStops(5);
|
|
119
116
|
const toggle = await DSToggleCO.getToggleFocuseableByIndex(16);
|
|
120
117
|
await expect(toggle).toBeFocused();
|
|
@@ -7,24 +7,23 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
7
7
|
const errorOnGo = await DSToggleCO.showOffURL.go();
|
|
8
8
|
if (errorOnGo) throw errorOnGo;
|
|
9
9
|
});
|
|
10
|
-
it('
|
|
10
|
+
it('should display all DSControlledToggle styles correctly', async () => {
|
|
11
11
|
await (await DSToggleCO.getToggleByIndex(0)).waitForExist();
|
|
12
12
|
const snapshot = await browser.checkSnapshot(DSToggleCO.snapshotPath('show-off'));
|
|
13
13
|
await expect(snapshot).toEqual(0);
|
|
14
14
|
});
|
|
15
15
|
});
|
|
16
|
-
|
|
17
16
|
describe('PUI-6758 - DSControlledToggle - Visual Test - Label', () => {
|
|
18
17
|
before('loading page', async () => {
|
|
19
18
|
const errorOnGo = await DSToggleCO.labelOnOff.go();
|
|
20
19
|
if (errorOnGo) throw errorOnGo;
|
|
21
20
|
});
|
|
22
|
-
it('
|
|
21
|
+
it('should display the label there correctly', async () => {
|
|
23
22
|
await (await DSToggleCO.getToggle()).waitForExist();
|
|
24
23
|
const snapshot = await browser.checkSnapshot(DSToggleCO.snapshotPath('label-there'));
|
|
25
24
|
await expect(snapshot).toEqual(0);
|
|
26
25
|
});
|
|
27
|
-
it('
|
|
26
|
+
it('should display the label hello correctly', async () => {
|
|
28
27
|
await (await DSToggleCO.getToggle()).click();
|
|
29
28
|
const snapshot = await browser.checkSnapshot(DSToggleCO.snapshotPath('label-hello'));
|
|
30
29
|
await expect(snapshot).toEqual(0);
|
|
@@ -35,7 +34,7 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
35
34
|
const errorOnGo = await DSToggleCO.behindModalSlideTest.go();
|
|
36
35
|
if (errorOnGo) throw errorOnGo;
|
|
37
36
|
});
|
|
38
|
-
it('
|
|
37
|
+
it('should display the modal slide (50% width) above the toggle there correctly', async () => {
|
|
39
38
|
const toggleModalSlide = await DSToggleCO.getToggleModalSlide();
|
|
40
39
|
await toggleModalSlide.click();
|
|
41
40
|
// eslint-disable-next-line wdio/no-pause
|
|
@@ -43,7 +42,7 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
43
42
|
const snapshot = await browser.checkSnapshot(DSToggleCO.snapshotPath('toggle-modalslide-half'));
|
|
44
43
|
await expect(snapshot).toEqual(0);
|
|
45
44
|
});
|
|
46
|
-
it('
|
|
45
|
+
it('should display the modal slide (full width) above the toggle correctly', async () => {
|
|
47
46
|
const enableFullWidth = await DSToggleCO.getToggleFullWidth();
|
|
48
47
|
await enableFullWidth.click();
|
|
49
48
|
const toggleModalSlide = await DSToggleCO.getToggleModalSlide();
|
|
@@ -54,47 +53,24 @@ if (!browser.capabilities['ice:options'].isPhone && !browser.capabilities['ice:o
|
|
|
54
53
|
await expect(snapshot).toEqual(0);
|
|
55
54
|
});
|
|
56
55
|
});
|
|
57
|
-
|
|
58
56
|
describe('PUI-14393 - [Toggle] applyAriaDisabled prop - visual Test', () => {
|
|
59
57
|
before('loading page', async () => {
|
|
60
58
|
const errorOnGo = await DSToggleCO.applyAriaDisabled.go();
|
|
61
59
|
if (errorOnGo) throw errorOnGo;
|
|
62
60
|
});
|
|
63
|
-
it('01:
|
|
64
|
-
await browser.eyesOpen();
|
|
65
|
-
const snapshot = await browser.eyesCheckSnapshot(DSToggleCO.snapshotPath('toggle-aria-disabled-default'));
|
|
66
|
-
await expect(snapshot).toEqual(0);
|
|
67
|
-
});
|
|
68
|
-
it('02: The fifth aria-disabled toggle should be focused w/ kb', async () => {
|
|
69
|
-
await browser.eyesOpen();
|
|
70
|
-
await browser.keys(Key.Tab);
|
|
71
|
-
await browser.keys(Key.Tab);
|
|
72
|
-
await browser.keys(Key.Tab);
|
|
73
|
-
const snapshot = await browser.eyesCheckSnapshot(DSToggleCO.snapshotPath('toggle-aria-disabled-kb-nav'));
|
|
74
|
-
await expect(snapshot).toEqual(0);
|
|
75
|
-
});
|
|
76
|
-
it('03: should display aria-disabled toggle not interacted', async () => {
|
|
61
|
+
it('01: the first aria-disabled toggle should be focused', async () => {
|
|
77
62
|
await browser.eyesOpen();
|
|
78
|
-
await
|
|
79
|
-
|
|
80
|
-
await disabledToggle.click();
|
|
63
|
+
const firstToggle = await DSToggleCO.getToggleByIndex(0);
|
|
64
|
+
await firstToggle.click();
|
|
81
65
|
const snapshot = await browser.eyesCheckSnapshot(DSToggleCO.snapshotPath('toggle-aria-disabled-mouse'));
|
|
82
66
|
await expect(snapshot).toEqual(0);
|
|
83
67
|
});
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
describe('PUI-14882 - DSControlledToggle:: Disabled -Visual', () => {
|
|
87
|
-
before('loading page', async () => {
|
|
88
|
-
const errorOnGo = await DSToggleCO.disabled.go();
|
|
89
|
-
if (errorOnGo) throw errorOnGo;
|
|
90
|
-
await (await DSToggleCO.getToggle()).waitForExist();
|
|
91
|
-
});
|
|
92
|
-
it('01: should display in disabled state toggle not focused', async () => {
|
|
68
|
+
it('02: The fifth aria-disabled toggle should be focused', async () => {
|
|
93
69
|
await browser.eyesOpen();
|
|
70
|
+
const fourthToggle = await DSToggleCO.getToggleByIndex(3);
|
|
71
|
+
await fourthToggle.click();
|
|
94
72
|
await browser.keys(Key.Tab);
|
|
95
|
-
const
|
|
96
|
-
await disabledToggle.click();
|
|
97
|
-
const snapshot = await browser.eyesCheckSnapshot(DSToggleCO.snapshotPath('toggle-disabled-notfocus'));
|
|
73
|
+
const snapshot = await browser.eyesCheckSnapshot(DSToggleCO.snapshotPath('toggle-aria-disabled-kb-nav'));
|
|
98
74
|
await expect(snapshot).toEqual(0);
|
|
99
75
|
});
|
|
100
76
|
});
|