dimsum-e2e-tests 3.80.0-next.3 → 3.80.0-next.31

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (122) hide show
  1. package/CHANGELOG.md +134 -0
  2. package/DSStorybook/baseline.js +0 -186
  3. package/ds-accordion/DSAccordion.visual.spec.js +0 -14
  4. package/ds-accordion/DSAccordionCO.js +0 -2
  5. package/ds-apppicker/aria-disabled/DSAppPicker.aria-disabled.visual.spec.js +14 -1
  6. package/ds-apppicker/basic/DSAppPicker.basic.visual.spec.js +12 -7
  7. package/ds-banner/DSBanner.text-wrapping.visual.spec.js +3 -6
  8. package/ds-banner/DSBanner.visual.spec.js +7 -8
  9. package/ds-banner/DSBannerCO.js +4 -5
  10. package/ds-banner/slots/DSBanner.slots.func.spec.js +6 -0
  11. package/ds-banner/slots/DSBanner.slots.visual.spec.js +1 -2
  12. package/ds-chip/DSChip.axe-core.func.spec.js +0 -17
  13. package/ds-chip/DSChip.visual.spec.js +0 -22
  14. package/ds-chip/DSChipCO.js +0 -6
  15. package/ds-fast-list/DSFastListCO.js +37 -0
  16. package/ds-fast-list/basic/DSFastList.basic.axe-core.func.spec.js +28 -0
  17. package/ds-fast-list/basic/DSFastList.basic.visual.spec.js +23 -0
  18. package/ds-fast-list/scroll-to-index/DSFastList.scroll-to-index.func.spec.js +45 -0
  19. package/ds-indeterminate-progress-indicator/DSIndeterminateProgressIndicatorCO.js +4 -0
  20. package/ds-indeterminate-progress-indicator/accessible-name/DSIndeterminateProgressIndicator.accessible-name.func.spec.js +51 -0
  21. package/ds-leftnavigation/LeftNavigation.fullFeatures.axe-core.func.spec.js +37 -0
  22. package/ds-leftnavigation/LeftNavigation.isSkeleton.axe-core.func.spec.js +23 -0
  23. package/ds-leftnavigation/LeftNavigation.keepingItems.axe-core.func.spec.js +34 -0
  24. package/ds-leftnavigation/LeftNavigation.loadingIndicator.axe-core.func.spec.js +41 -0
  25. package/ds-leftnavigation/LeftNavigation.notificationBadge.axe-core.func.spec.js +21 -0
  26. package/ds-leftnavigation/LeftNavigation.searchBar.axe-core.func.spec.js +26 -0
  27. package/ds-leftnavigation/LeftNavigation.showCase.axe-core.func.spec.js +23 -0
  28. package/ds-leftnavigation/LeftNavigation.tooltip.axe-core.func.spec.js +28 -0
  29. package/ds-leftnavigation/LeftNavigation.wrappedText.axe-core.func.spec.js +27 -0
  30. package/ds-panel-header/DSPanelHeader.func.spec.js +24 -0
  31. package/ds-panel-header/DSPanelHeaderCO.js +17 -0
  32. package/ds-pills-v2/DSPillsV2CO.js +53 -1
  33. package/ds-pills-v2/pitfalls/DSPills.inputPill.func.spec.js +26 -0
  34. package/ds-pills-v2/pitfalls/DSPills.inputWithFormItemBlockURL.axe-core.func.spec.js +38 -0
  35. package/ds-pills-v2/pitfalls/DSPills.inputWithFormItemBlockURL.func.spec.js +72 -0
  36. package/ds-progress-indicator/DSProgressIndicator.axe-core.func.spec.js +8 -5
  37. package/ds-progress-indicator/DSProgressIndicator.func.spec.js +31 -4
  38. package/ds-progress-indicator/DSProgressIndicator.visual.spec.js +14 -6
  39. package/ds-progress-indicator/DSProgressIndicatorCO.js +87 -9
  40. package/ds-progress-indicator/aria-contract/DSProgressIndicator.aria-contract.func.spec.js +104 -0
  41. package/ds-progress-indicator/slots/DSProgressIndicator.slots.axe-core.func.spec.js +31 -0
  42. package/ds-progress-indicator/slots/DSProgressIndicator.slots.func.spec.js +87 -0
  43. package/ds-progress-indicator/slots/DSProgressIndicator.slots.visual.spec.js +27 -0
  44. package/ds-progress-indicator/variant/DSProgressIndicator.single-bar-variant.func.spec.js +44 -0
  45. package/ds-progress-indicator/variant/DSProgressIndicator.single-bar-variant.visual.spec.js +19 -0
  46. package/ds-slider-v2/DSSliderV2.axe-core.func.spec.js +21 -0
  47. package/ds-slider-v2/DSSliderV2.visual.spec.js +19 -1
  48. package/ds-slider-v2/DSSliderV2CO.js +6 -1
  49. package/ds-slider-v2/has-error/DSSliderV2.has-error.visual.spec.js +44 -0
  50. package/ds-slider-v2/interaction-states/DSSliderV2.interaction-states.visual.spec.js +53 -0
  51. package/ds-virtuallist/DSVirtualList.visual.spec.js +4 -5
  52. package/ds-virtuallist/DSVirtualListCO.js +28 -9
  53. package/ds-virtuallist/basic/DSVirtualList.basic.axe-core.func.spec.js +28 -0
  54. package/ds-virtuallist/scroll-to-index/DSVirtualList.scroll-to-index.func.spec.js +45 -0
  55. package/package.json +149 -149
  56. package/paths.js +3 -49
  57. package/ds-leftnavigation/LeftNavigation.axe-core.func.spec.js +0 -172
  58. package/ds-mobile/Accordion/DSAccordion.visual.spec.js +0 -33
  59. package/ds-mobile/Accordion/DSAccordionCO.js +0 -37
  60. package/ds-mobile/CategoryBox/CategoryBox.visual.spec.js +0 -18
  61. package/ds-mobile/CategoryBox/CategoryBoxCO.js +0 -17
  62. package/ds-mobile/CollectionBox/CollectionBox.visual.spec.js +0 -16
  63. package/ds-mobile/CollectionBox/CollectionBoxCO.js +0 -15
  64. package/ds-mobile/GlobalHeader/DSGlobalHeader.visual.spec.js +0 -55
  65. package/ds-mobile/GlobalHeader/DSGlobalHeaderCO.js +0 -36
  66. package/ds-mobile/GroupBox/GroupBox.visual.spec.js +0 -15
  67. package/ds-mobile/GroupBox/GroupBoxCO.js +0 -15
  68. package/ds-mobile/InfiniteLoader/InfiniteLoader.func.spec.js +0 -90
  69. package/ds-mobile/InfiniteLoader/InfiniteLoaderCO.js +0 -29
  70. package/ds-mobile/MobileActionToolbar/MobileActionToolbar.visual.spec.js +0 -39
  71. package/ds-mobile/MobileActionToolbar/MobileActionToolbarCO.js +0 -19
  72. package/ds-mobile/MobileBanner/MobileBanner.visual.spec.js +0 -23
  73. package/ds-mobile/MobileBanner/MobileBannerCO.js +0 -23
  74. package/ds-mobile/MobileCard/Card.func.spec.js +0 -38
  75. package/ds-mobile/MobileCard/Card.visual.spec.js +0 -103
  76. package/ds-mobile/MobileCard/MobileCardCO.js +0 -42
  77. package/ds-mobile/MobileContextMenu/MobileContextMenu.func.spec.js +0 -88
  78. package/ds-mobile/MobileContextMenu/MobileContextMenu.visual.spec.js +0 -31
  79. package/ds-mobile/MobileContextMenu/MobileContextMenuCO.js +0 -72
  80. package/ds-mobile/MobileDatePicker/MobileDatePicker.func.spec.js +0 -15
  81. package/ds-mobile/MobileDatePicker/MobileDatePicker.visual.spec.js +0 -15
  82. package/ds-mobile/MobileDatePicker/MobileDatePickerCO.js +0 -35
  83. package/ds-mobile/MobileDropdownMenu/MobileDropdownMenu.func.spec.js +0 -38
  84. package/ds-mobile/MobileDropdownMenu/MobileDropdownMenu.visual.spec.js +0 -16
  85. package/ds-mobile/MobileDropdownMenu/MobileDropdownMenuCO.js +0 -37
  86. package/ds-mobile/MobileEmptyState/MobileEmptyState.visual.spec.js +0 -15
  87. package/ds-mobile/MobileEmptyState/MobileEmptyStateCO.js +0 -14
  88. package/ds-mobile/MobileFilterbar/MobileFilterbar.visual.spec.js +0 -39
  89. package/ds-mobile/MobileFilterbar/MobileFilterbarCO.js +0 -19
  90. package/ds-mobile/MobileFooter/MobileFooter.func.spec.js +0 -26
  91. package/ds-mobile/MobileFooter/MobileFooter.visual.spec.js +0 -51
  92. package/ds-mobile/MobileFooter/MobileFooterCO.js +0 -27
  93. package/ds-mobile/MobileListItem/MobileListItem.visual.spec.js +0 -56
  94. package/ds-mobile/MobileListItem/MobileListItemCO.js +0 -19
  95. package/ds-mobile/MobileLoadingPage/MobileLoadingPage.visual.spec.js +0 -37
  96. package/ds-mobile/MobileLoadingPage/MobileLoadingPageCO.js +0 -23
  97. package/ds-mobile/MobilePageHeader/MobilePageHeader.func.spec.js +0 -22
  98. package/ds-mobile/MobilePageHeader/MobilePageHeader.visual.spec.js +0 -135
  99. package/ds-mobile/MobilePageHeader/MobilePageHeaderCO.js +0 -67
  100. package/ds-mobile/MobileSelectList/MobileSelectList.visual.spec.js +0 -56
  101. package/ds-mobile/MobileSelectList/MobileSelectListCO.js +0 -21
  102. package/ds-mobile/MobileSeparator/MobileSeparator.visual.spec.js +0 -28
  103. package/ds-mobile/MobileSeparator/MobileSeparatorCO.js +0 -17
  104. package/ds-mobile/MobileTimePicker/MobileTimePickerCO.js +0 -41
  105. package/ds-mobile/Modal/MobileModal.visual.spec.js +0 -56
  106. package/ds-mobile/Modal/MobileModalCO.js +0 -28
  107. package/ds-mobile/PageFilter/PageFilter.visual.spec.js +0 -46
  108. package/ds-mobile/PageFilter/PageFilterCO.js +0 -19
  109. package/ds-mobile/PageForm/PageForm.visual.spec.js +0 -14
  110. package/ds-mobile/PageForm/PageFormCO.js +0 -11
  111. package/ds-mobile/PageList/PageList.visual.spec.js +0 -31
  112. package/ds-mobile/PageList/PageListCO.js +0 -19
  113. package/ds-mobile/PageSummary/PageSummary.visual.spec.js +0 -20
  114. package/ds-mobile/PageSummary/PageSummaryCO.js +0 -11
  115. package/ds-mobile/SwipeToRefresh/SwipeToRefresh.func.spec.js +0 -26
  116. package/ds-mobile/SwipeToRefresh/SwipeToRefreshCO.js +0 -20
  117. package/ds-mobile/Tabs/MobileTabs.visual.spec.js +0 -91
  118. package/ds-mobile/Tabs/TabsCO.js +0 -37
  119. package/ds-mobile/Tooltip/MobileTooltip.func.spec.js +0 -17
  120. package/ds-mobile/Tooltip/MobileTooltip.visual.spec.js +0 -16
  121. package/ds-mobile/Tooltip/TooltipCO.js +0 -23
  122. package/ds-mobile/helpers.js +0 -7
@@ -1,37 +0,0 @@
1
- /* eslint-disable import/no-relative-packages */
2
- import { PATH_MOBILE_ACCORDION_EXAMPLES } from '../../paths';
3
- import { PageObject, Urlbuilder } from '../helpers';
4
-
5
- export const knobs = {
6
- title: 'knob-Accordion%20Item%20title%200',
7
- };
8
-
9
- class DSAccordionCO {
10
- static basicURL = new Urlbuilder(PATH_MOBILE_ACCORDION_EXAMPLES, 'basic');
11
-
12
- static truncatedURL = new Urlbuilder(PATH_MOBILE_ACCORDION_EXAMPLES, 'truncated-title');
13
-
14
- static getUrl(example = 'basic') {
15
- return PageObject.getUrl(PATH_MOBILE_ACCORDION_EXAMPLES, example);
16
- }
17
-
18
- // Snapshots
19
- static snapshotPath(example = 'basic') {
20
- return PageObject.getSnapshotPathBuilder('Accordion', example, 'ds-mobile');
21
- }
22
-
23
- // selectors
24
- static async getAccordionItem(index) {
25
- return $$('[data-testid="ds-accordion_item"]')[index];
26
- }
27
-
28
- static async getHeaderClickableElement(index) {
29
- return $$('[data-testid="ds-accordion_item-header"]')[index];
30
- }
31
-
32
- static async getContent() {
33
- return $('[data-testid="ds-accordion_item-content"]');
34
- }
35
- }
36
-
37
- export default DSAccordionCO;
@@ -1,18 +0,0 @@
1
- import CategoryBoxCO from './CategoryBoxCO';
2
-
3
- // PUI-3907 - Mobile CategoryBox
4
- if (browser.capabilities['ice:options'].isPhone) {
5
- describe('Mobile CategoryBox', () => {
6
- describe('Mobile CategoryBox:: Basic', () => {
7
- before('loading page', async () => {
8
- const errorOnGo = await CategoryBoxCO.basicURL.go();
9
- if (errorOnGo) throw errorOnGo;
10
- });
11
- it('basic snapshot', async () => {
12
- await (await CategoryBoxCO.getHeaderText()).waitForDisplayed({ timeout: 5000 });
13
- const snapshot = await browser.checkSnapshot(CategoryBoxCO.snapshotPath());
14
- await expect(snapshot).toEqual(0);
15
- });
16
- });
17
- });
18
- }
@@ -1,17 +0,0 @@
1
- import { PATH_MOBILE_CATEGORY_BOX } from '../../paths';
2
- import { PageObject, Urlbuilder } from '../helpers';
3
-
4
- export default class CategoryBox extends PageObject {
5
- static basicURL = new Urlbuilder(PATH_MOBILE_CATEGORY_BOX, 'basic');
6
-
7
- static actionsURL = new Urlbuilder(PATH_MOBILE_CATEGORY_BOX, 'actions');
8
-
9
- static async getHeaderText() {
10
- return $('div*=Category box title');
11
- }
12
-
13
- // Snapshots
14
- static snapshotPath(example = 'basic') {
15
- return PageObject.getSnapshotPathBuilder('CategoryBox', example, 'ds-mobile');
16
- }
17
- }
@@ -1,16 +0,0 @@
1
- import CollectionBoxCO from './CollectionBoxCO';
2
-
3
- // PUI-3906 - CollectionBox
4
- if (browser.capabilities['ice:options'].isPhone) {
5
- describe('Mobile CollectionBox:: Basic', () => {
6
- before('loading page', async () => {
7
- const errorOnGo = await CollectionBoxCO.basicURL.go();
8
- if (errorOnGo) throw errorOnGo;
9
- });
10
- it('basic snapshot', async () => {
11
- await (await CollectionBoxCO.getHeaderText()).waitForDisplayed({ timeout: 5000 });
12
- const snapshot = await browser.checkSnapshot(CollectionBoxCO.snapshotPath());
13
- await expect(snapshot).toEqual(0);
14
- });
15
- });
16
- }
@@ -1,15 +0,0 @@
1
- import { PATH_MOBILE_COLLECTION_BOX } from '../../paths';
2
- import { PageObject, Urlbuilder } from '../helpers';
3
-
4
- export default class CollectionBox extends PageObject {
5
- static basicURL = new Urlbuilder(PATH_MOBILE_COLLECTION_BOX, 'basic');
6
-
7
- static async getHeaderText() {
8
- return $('div*=Header');
9
- }
10
-
11
- // Snapshots
12
- static snapshotPath(example = 'basic') {
13
- return PageObject.getSnapshotPathBuilder('CollectionBox', example, 'ds-mobile');
14
- }
15
- }
@@ -1,55 +0,0 @@
1
- import DSGlobalHeaderCO from './DSGlobalHeaderCO';
2
-
3
- if (browser.capabilities['ice:options'].isPhone) {
4
- describe('PUI-4522 - Mobile Global Header, visual test', () => {
5
- before('loading page', async () => {
6
- const errorOnGo = await DSGlobalHeaderCO.basicURL.go();
7
- if (errorOnGo) throw errorOnGo;
8
- });
9
- it('01: should display mobileGlobalHeader basic', async () => {
10
- await (await DSGlobalHeaderCO.getGlobalHeaderItem(0)).waitForDisplayed();
11
- const snapshot = await browser.checkSnapshot(DSGlobalHeaderCO.snapshotPath('mobile-global-header-basic'));
12
- await expect(snapshot).toEqual(0);
13
- });
14
- });
15
- describe('PUI-10842 - MobileGlobalHeader, with icon', () => {
16
- before('loading page', async () => {
17
- const errorOnGo = await DSGlobalHeaderCO.withIconURL.go();
18
- if (errorOnGo) throw errorOnGo;
19
- });
20
- it('01: should display mobileGlobalHeader with icon', async () => {
21
- await (await DSGlobalHeaderCO.getGlobalHeaderItem(0)).waitForDisplayed();
22
- const snapshot = await browser.checkSnapshot(DSGlobalHeaderCO.snapshotPath('mobile-global-header-withIcon'));
23
- await expect(snapshot).toEqual(0);
24
- });
25
- });
26
- describe('PUI-10843 - MobileGlobalHeader, menu opened', () => {
27
- before('loading page', async () => {
28
- const errorOnGo = await DSGlobalHeaderCO.withMenuURL.go();
29
- if (errorOnGo) throw errorOnGo;
30
- });
31
- it('01: should display mobielGlobalHeader with menu opened', async () => {
32
- await (await DSGlobalHeaderCO.getGlobalHeaderItem(0)).waitForDisplayed();
33
- const r = await DSGlobalHeaderCO.getMenuClickableElement();
34
- await r.click();
35
- await (await DSGlobalHeaderCO.getGlobalHeaderMenu()).waitForDisplayed();
36
- const snapshot = await browser.checkSnapshot(DSGlobalHeaderCO.snapshotPath('mobile-global-header-menu-opened'));
37
- await expect(snapshot).toEqual(0);
38
- });
39
- });
40
- describe('PUI-10844 - MobileGlobalHeader, searchbox opened', () => {
41
- before('loading page', async () => {
42
- const errorOnGo = await DSGlobalHeaderCO.basicURL.go();
43
- if (errorOnGo) throw errorOnGo;
44
- });
45
- it('01: should display searchbox open', async () => {
46
- await (await DSGlobalHeaderCO.getGlobalHeaderItem(0)).waitForDisplayed();
47
- await (await DSGlobalHeaderCO.getSearchIconDisplay()).waitForDisplayed();
48
- const r = await DSGlobalHeaderCO.getSearchIconDisplay();
49
- await r.click();
50
- await (await DSGlobalHeaderCO.getSearchBox()).waitForDisplayed({ timeout: 5000 });
51
- const snapshot = await browser.checkSnapshot(DSGlobalHeaderCO.snapshotPath('mobile-global-header-search-open'));
52
- await expect(snapshot).toEqual(0);
53
- });
54
- });
55
- }
@@ -1,36 +0,0 @@
1
- import { PATH_MOBILE_GLOBAL_HEADER } from '../../paths';
2
- import { PageObject, Urlbuilder } from '../helpers';
3
-
4
- class DSGlobalHeaderCO {
5
- static basicURL = new Urlbuilder(PATH_MOBILE_GLOBAL_HEADER, 'basic');
6
-
7
- static withIconURL = new Urlbuilder(PATH_MOBILE_GLOBAL_HEADER, 'with-icon');
8
-
9
- static withMenuURL = new Urlbuilder(PATH_MOBILE_GLOBAL_HEADER, 'with-menu');
10
-
11
- static async getGlobalHeaderItem(index) {
12
- return $$('[data-testid="global-header-wrapper"]')[index];
13
- }
14
-
15
- static snapshotPath(example = 'basic') {
16
- return PageObject.getSnapshotPathBuilder('GlobalHeader', example, 'ds-mobile');
17
- }
18
-
19
- static async getMenuClickableElement() {
20
- return (await DSGlobalHeaderCO.getGlobalHeaderItem(0)).$(`div`).$('div');
21
- }
22
-
23
- static async getSearchIconDisplay() {
24
- return $('[data-testid="mobile-global-header-search"]');
25
- }
26
-
27
- static async getGlobalHeaderMenu() {
28
- return $('[data-testid="global-header-menu"]');
29
- }
30
-
31
- static async getSearchBox() {
32
- return $('[data-testid="ds-input_main-component"]');
33
- }
34
- }
35
-
36
- export default DSGlobalHeaderCO;
@@ -1,15 +0,0 @@
1
- import GroupBoxCO from './GroupBoxCO';
2
-
3
- if (browser.capabilities['ice:options'].isPhone) {
4
- describe('PUI-3909 - MobileGroupBox:: Basic', () => {
5
- before('loading page', async () => {
6
- const errorOnGo = await GroupBoxCO.basicURL.go();
7
- if (errorOnGo) throw errorOnGo;
8
- });
9
- it('basic snapshot', async () => {
10
- await (await GroupBoxCO.getGroupBoxHeader()).waitForDisplayed({ timeout: 5000 });
11
- const snapshot = await browser.checkSnapshot(GroupBoxCO.snapshotPath());
12
- await expect(snapshot).toEqual(0);
13
- });
14
- });
15
- }
@@ -1,15 +0,0 @@
1
- import { PATH_MOBILE_GROUP_BOX } from '../../paths';
2
- import { PageObject, Urlbuilder } from '../helpers';
3
-
4
- export default class GroupBox extends PageObject {
5
- static basicURL = new Urlbuilder(PATH_MOBILE_GROUP_BOX, 'basic');
6
-
7
- static async getGroupBoxHeader() {
8
- return $('div*=Group box title');
9
- }
10
-
11
- // Snapshots
12
- static snapshotPath(example = 'basic') {
13
- return PageObject.getSnapshotPathBuilder('GroupBox', example, 'ds-mobile');
14
- }
15
- }
@@ -1,90 +0,0 @@
1
- /* eslint-disable wdio/no-pause */
2
- import InfiniteLoaderCO from './InfiniteLoaderCO';
3
-
4
- if (browser.capabilities['ice:options'].isPhone) {
5
- describe('PUI-4353 - InfiniteLoader - display Loader', () => {
6
- before('loading page', async () => {
7
- const errorOnGo = await InfiniteLoaderCO.basic.go();
8
- if (errorOnGo) throw errorOnGo;
9
- });
10
- it('should display loader when scroll down', async () => {
11
- const card7 = await InfiniteLoaderCO.getCard(7);
12
- await card7.waitForDisplayed();
13
- await card7.scrollIntoView();
14
- const loaderIndicator = await InfiniteLoaderCO.getLoaderIndicator();
15
- await loaderIndicator.waitForDisplayed();
16
- await expect(loaderIndicator).toBeDisplayed();
17
- });
18
- it('should display more cards', async () => {
19
- const card7 = await InfiniteLoaderCO.getCard(7);
20
- await card7.waitForDisplayed();
21
- await card7.scrollIntoView();
22
- const card8 = await InfiniteLoaderCO.getCard(8);
23
- await card8.waitForDisplayed();
24
- await card8.scrollIntoView();
25
- const card9 = await InfiniteLoaderCO.getCard(9);
26
- await expect(card9).toBeDisplayed();
27
- });
28
- });
29
- describe('PUI-8865 - InfiniteLoader - hasMoreItems prop', () => {
30
- before('loading page', async () => {
31
- const errorOnGo = await InfiniteLoaderCO.hasMoreItems.go();
32
- if (errorOnGo) throw errorOnGo;
33
- });
34
- it('should display loader when scroll down', async () => {
35
- const card7 = await InfiniteLoaderCO.getCard(7);
36
- await card7.waitForDisplayed();
37
- await card7.scrollIntoView();
38
- const loaderIndicator = await InfiniteLoaderCO.getLoaderIndicator();
39
- await expect(loaderIndicator).toBeDisplayed();
40
- });
41
- it('should display loader when scroll down - 2nd scroll', async () => {
42
- await browser.pause(800);
43
- const loaderIndicator = await InfiniteLoaderCO.getLoaderIndicator();
44
- await loaderIndicator.waitForDisplayed({ reverse: true });
45
- const card9 = await InfiniteLoaderCO.getCard(9);
46
- await card9.waitForDisplayed();
47
- await card9.scrollIntoView();
48
- await expect(loaderIndicator).toBeDisplayed();
49
- });
50
- it('should not display loading indicator', async () => {
51
- await browser.pause(800);
52
- const loaderIndicator = await InfiniteLoaderCO.getLoaderIndicator();
53
- await loaderIndicator.waitForDisplayed({ reverse: true });
54
- const card10 = await InfiniteLoaderCO.getCard(10);
55
- await card10.waitForDisplayed();
56
- await card10.scrollIntoView({ behavior: 'smooth', block: 'nearest', inline: 'start' });
57
- await expect(loaderIndicator).not.toBeDisplayed();
58
- });
59
- });
60
-
61
- // to improve, is not working as expected and with intermitent issues
62
- // describe('PUI-4571 - InfiniteLoader - combine with swipe', () => {
63
- // beforeEach('loading page', async () => {
64
- // const errorOnGo = await InfiniteLoaderCO.basic.go();
65
- // if (errorOnGo) throw errorOnGo;
66
- // });
67
- // it('scroll down and then swipe to refresh', async () => {
68
- // InfiniteLoaderCO.getCard(7).waitForDisplayed();
69
- // InfiniteLoaderCO.getCard(9).scrollIntoView();
70
- // InfiniteLoaderCO.getLoaderIndicator().waitForDisplayed();
71
- // expect(await InfiniteLoaderCO.getLoaderIndicator()).toBeDisplayedInViewport();
72
- // expect(await $('div*=20')).toBeDisplayed();
73
- // InfiniteLoaderCO.getCard(0).scrollIntoView();
74
- // await browser.pause(500);
75
- // Gestures.swipeDown();
76
- // InfiniteLoaderCO.getLoaderBox().waitForDisplayed();
77
- // expect(await InfiniteLoaderCO.getLoaderBox()).toBeDisplayedInViewport();
78
- // });
79
- // it('swipe to refresh and then scroll down', async () => {
80
- // InfiniteLoaderCO.getCard(9).waitForDisplayed();
81
- // Gestures.swipeDown();
82
- // InfiniteLoaderCO.getLoaderBox().waitForDisplayed();
83
- // expect(await InfiniteLoaderCO.getLoaderBox()).toBeDisplayedInViewport();
84
- // InfiniteLoaderCO.getCard(9).scrollIntoView();
85
- // InfiniteLoaderCO.getLoaderIndicator().waitForDisplayed();
86
- // expect(await InfiniteLoaderCO.getLoaderIndicator()).toBeDisplayedInViewport();
87
- // expect(await $('div*=20')).toBeDisplayed();
88
- // });
89
- // });
90
- }
@@ -1,29 +0,0 @@
1
- // eslint-disable-next-line import/no-relative-packages
2
- import { PATH_MOBILE_INFINITE_LOADER } from '../../paths';
3
- import { PageObject, Urlbuilder } from '../helpers';
4
-
5
- export default class InfiniteLoader extends PageObject {
6
- static basic = new Urlbuilder(PATH_MOBILE_INFINITE_LOADER, 'basic');
7
-
8
- static conbineWithSwipe = new Urlbuilder(PATH_MOBILE_INFINITE_LOADER, 'combine-with-swipe');
9
-
10
- static hasMoreItems = new Urlbuilder(PATH_MOBILE_INFINITE_LOADER, 'has-more-items');
11
-
12
- // Selectors
13
- static async getLoaderIndicator() {
14
- return $('.opened');
15
- }
16
-
17
- static async getCard(index) {
18
- return $$('[data-testid="card-title"]')[index];
19
- }
20
-
21
- static async getLoaderBox() {
22
- return $('[data-testid="loader-box"]');
23
- }
24
-
25
- // Snapshots
26
- static snapshotPath(example = 'actions') {
27
- return PageObject.getSnapshotPathBuilder('InfiniteLoader', example, 'ds-mobile');
28
- }
29
- }
@@ -1,39 +0,0 @@
1
- import MATCO from './MobileActionToolbarCO';
2
-
3
- if (browser.capabilities['ice:options'].isPhone) {
4
- describe('Mobile Action Toolbar', () => {
5
- describe('ActionToolbar - no border', () => {
6
- before('loading page', async () => {
7
- const errorOnGo = await MATCO.noBorderUrl.go();
8
- if (errorOnGo) throw errorOnGo;
9
- });
10
- it('should display mobile action toolbar without border', async () => {
11
- await (await MATCO.getTopContent()).waitForDisplayed({ timeout: 10000 });
12
- const snapshot = await browser.checkSnapshot(MATCO.snapshotPath('no-border'));
13
- await expect(snapshot).toEqual(0);
14
- });
15
- });
16
- describe('ActionToolbar - more items', () => {
17
- before('loading page', async () => {
18
- const errorOnGo = await MATCO.moreItemsUrl.go();
19
- if (errorOnGo) throw errorOnGo;
20
- });
21
- it('should display mobile action toolbar with five buttons', async () => {
22
- await (await MATCO.getTopContent()).waitForDisplayed({ timeout: 10000 });
23
- const snapshot = await browser.checkSnapshot(MATCO.snapshotPath('more-items'));
24
- await expect(snapshot).toEqual(0);
25
- });
26
- });
27
- describe('ActionToolbar - basic', () => {
28
- before('loading page', async () => {
29
- const errorOnGo = await MATCO.basicURL.go();
30
- if (errorOnGo) throw errorOnGo;
31
- });
32
- it('should display mobile action toolbar basic', async () => {
33
- await (await MATCO.getTopContent()).waitForDisplayed({ timeout: 10000 });
34
- const snapshot = await browser.checkSnapshot(MATCO.snapshotPath('basic'));
35
- await expect(snapshot).toEqual(0);
36
- });
37
- });
38
- });
39
- }
@@ -1,19 +0,0 @@
1
- import { PATH_MOBILE_ACTION_TOOLBAR } from '../../paths';
2
- import { PageObject, Urlbuilder } from '../helpers';
3
-
4
- export default class MobileActionToolbar extends PageObject {
5
- static basicURL = new Urlbuilder(PATH_MOBILE_ACTION_TOOLBAR, 'basic');
6
-
7
- static noBorderUrl = new Urlbuilder(PATH_MOBILE_ACTION_TOOLBAR, 'without-border');
8
-
9
- static moreItemsUrl = new Urlbuilder(PATH_MOBILE_ACTION_TOOLBAR, 'more-items');
10
-
11
- static async getTopContent() {
12
- return $('div*=Top Content');
13
- }
14
-
15
- // Snapshots
16
- static snapshotPath(example = 'basic') {
17
- return PageObject.getSnapshotPathBuilder('MobileActionToolbar', example, 'ds-mobile');
18
- }
19
- }
@@ -1,23 +0,0 @@
1
- import MobileBannerCO from './MobileBannerCO';
2
-
3
- if (browser.capabilities['ice:options'].isPhone) {
4
- describe('PUI-6716 - MobileBanner: types - visual test', () => {
5
- before('loading page', async () => {
6
- const errorOnGo = await MobileBannerCO.type.go();
7
- if (errorOnGo) throw errorOnGo;
8
- });
9
- it('should display all mobile banner types', async () => {
10
- const container = await MobileBannerCO.getContainer(0);
11
- await container.waitForDisplayed();
12
- const snapshot = await browser.checkSnapshot(MobileBannerCO.snapshotPath('types'));
13
- await expect(snapshot).toEqual(0);
14
- });
15
- it('should close correctly info mobile banner', async () => {
16
- const closeBtn = await MobileBannerCO.getCloseBtn(1);
17
- await closeBtn.click();
18
- await browser.pause(500);
19
- const snapshot = await browser.checkSnapshot(MobileBannerCO.snapshotPath('one-closed'));
20
- await expect(snapshot).toEqual(0);
21
- });
22
- });
23
- }
@@ -1,23 +0,0 @@
1
- import { PATH_MOBILE_BANNER } from '../../paths';
2
- import { PageObject, Urlbuilder } from '../helpers';
3
-
4
- export default class MobileBanner extends PageObject {
5
- static type = new Urlbuilder(PATH_MOBILE_BANNER, 'type');
6
-
7
- static async getContainers() {
8
- return $$('[data-testid="ds-mobile-banner-container"]');
9
- }
10
-
11
- static async getContainer(index) {
12
- return (await this.getContainers())[index];
13
- }
14
-
15
- static async getCloseBtn(index) {
16
- return $$('[data-testid="ds-mobile-banner-close-button"]')[index];
17
- }
18
-
19
- // Snapshots
20
- static snapshotPath(example = 'with-props') {
21
- return PageObject.getSnapshotPathBuilder('MobileBanner', example, 'ds-mobile-banner');
22
- }
23
- }
@@ -1,38 +0,0 @@
1
- import MobileCardCO from './MobileCardCO';
2
-
3
- if (browser.capabilities['ice:options'].isPhone) {
4
- describe('PUI-4696 - MobileCard expand cards', () => {
5
- // to be refactored in the future
6
- // describe('Expand cards', () => {
7
- // before('loading page', async () => {
8
- // const errorOnGo = await MobileCardCO.expandableURL.go();
9
- // if (errorOnGo) throw errorOnGo;
10
- // });
11
- // it('expands expandable touchable card', async () => {
12
- // await (await MobileCardCO.expandCard(0)).waitForDisplayed();
13
- // let cardContent = await MobileCardCO.getCardContent('111111');
14
- // await expect(cardContent).not.toBeDisplayedInViewport();
15
- // await (await MobileCardCO.expandCard(0)).click();
16
- // cardContent = await MobileCardCO.getCardContent('111111');
17
- // await expect(cardContent).toBeDisplayedInViewport();
18
- // });
19
- // });
20
- describe('Expand cards with allowMultipleOpen prop', () => {
21
- before('loading page', async () => {
22
- const errorOnGo = await MobileCardCO.multiExpandableURL.go();
23
- if (errorOnGo) throw errorOnGo;
24
- });
25
- it('expands multiple expandable touchable card', async () => {
26
- await (await MobileCardCO.expandCard(0)).waitForDisplayed();
27
- await (await MobileCardCO.expandCard(0)).click();
28
- let cardContent = await MobileCardCO.getCardContent('215693');
29
- await expect(cardContent).toBeDisplayedInViewport();
30
- await (await MobileCardCO.expandCard(1)).click();
31
- cardContent = await MobileCardCO.getCardContent('215693');
32
- await expect(cardContent).toBeDisplayedInViewport();
33
- cardContent = await MobileCardCO.getCardContent('215622');
34
- await expect(cardContent).toBeDisplayedInViewport();
35
- });
36
- });
37
- });
38
- }
@@ -1,103 +0,0 @@
1
- import MobileCardCO from './MobileCardCO';
2
-
3
- if (browser.capabilities['ice:options'].isPhone) {
4
- describe('PUI-4152 - MobileCard::', () => {
5
- describe('mobile card with props', () => {
6
- before('loading page', async () => {
7
- const errorOnGo = await MobileCardCO.withPropsURL.go();
8
- if (errorOnGo) throw errorOnGo;
9
- });
10
- it('should display mobile card with props', async () => {
11
- await (await MobileCardCO.getCardTitle()).waitForDisplayed();
12
- const snapshot = await browser.checkSnapshot(MobileCardCO.snapshotPath('with-props'));
13
- await expect(snapshot).toEqual(0);
14
- });
15
- });
16
- describe('mobile car with small height', () => {
17
- before('loading page', async () => {
18
- const errorOnGo = await MobileCardCO.smallHeightURL.go();
19
- if (errorOnGo) throw errorOnGo;
20
- });
21
- it('should display mobile card with small height', async () => {
22
- await (await MobileCardCO.getCardTitle()).waitForDisplayed();
23
- const snapshot = await browser.checkSnapshot(MobileCardCO.snapshotPath('small-height'));
24
- await expect(snapshot).toEqual(0);
25
- });
26
- });
27
- describe('mobile card group', () => {
28
- before('loading page', async () => {
29
- const errorOnGo = await MobileCardCO.cardGroupURL.go();
30
- if (errorOnGo) throw errorOnGo;
31
- });
32
- it('should display mobile card group', async () => {
33
- await (await MobileCardCO.getCardTitle()).waitForDisplayed();
34
- const snapshot = await browser.checkSnapshot(MobileCardCO.snapshotPath('card-group'));
35
- await expect(snapshot).toEqual(0);
36
- });
37
- });
38
- describe('mobile card group with no title', () => {
39
- before('loading page', async () => {
40
- const errorOnGo = await MobileCardCO.cardGroupNoTitleURL.go();
41
- if (errorOnGo) throw errorOnGo;
42
- });
43
-
44
- it('should display mobile card group with no title', async () => {
45
- await (await MobileCardCO.getCardTitle()).waitForDisplayed();
46
- const snapshot = await browser.checkSnapshot(MobileCardCO.snapshotPath('card-group-no-title'));
47
- await expect(snapshot).toEqual(0);
48
- });
49
- });
50
-
51
- describe('mobile card with details, subtext and props', () => {
52
- before('loading page', async () => {
53
- const errorOnGo = await MobileCardCO.withDetailsURL.go();
54
- if (errorOnGo) throw errorOnGo;
55
- });
56
- it('should display mobile card with details, subtext and props', async () => {
57
- await (await MobileCardCO.getCardTitle()).waitForDisplayed();
58
- const snapshot = await browser.checkSnapshot(MobileCardCO.snapshotPath('with-details-subtext-and-props'));
59
- await expect(snapshot).toEqual(0);
60
- });
61
- });
62
- describe('mobile card with icons', () => {
63
- before('loading page', async () => {
64
- const errorOnGo = await MobileCardCO.withIconsURL.go();
65
- if (errorOnGo) throw errorOnGo;
66
- });
67
- it('should display mobile card with icons', async () => {
68
- await (await MobileCardCO.getCardTitle()).waitForDisplayed();
69
- const snapshot = await browser.checkSnapshot(MobileCardCO.snapshotPath('with-icons'));
70
- await expect(snapshot).toEqual(0);
71
- });
72
- });
73
- describe('MobileCard:: Single Expandable', () => {
74
- before('loading page', async () => {
75
- const errorOnGo = await MobileCardCO.expandableURL.go();
76
- if (errorOnGo) throw errorOnGo;
77
- });
78
- it('should display cards expanded', async () => {
79
- await (await MobileCardCO.getCardTitle()).waitForDisplayed();
80
- await (await MobileCardCO.expandCard(0)).click();
81
- await (await MobileCardCO.getCardContent('111111')).waitForDisplayed();
82
- const snapshot = await browser.checkSnapshot(MobileCardCO.snapshotPath('single-expandable'));
83
- await expect(snapshot).toEqual(0);
84
- });
85
- });
86
-
87
- describe('MobileCard:: Multi Expandable', () => {
88
- before('loading page', async () => {
89
- const errorOnGo = await MobileCardCO.multiExpandableURL.go();
90
- if (errorOnGo) throw errorOnGo;
91
- });
92
- it('should display multiple cards expanded', async () => {
93
- await (await MobileCardCO.getCardTitle()).waitForDisplayed();
94
- await (await MobileCardCO.expandCard(1)).click();
95
- await (await MobileCardCO.getCardContent('215622')).waitForDisplayed();
96
- await (await MobileCardCO.expandCard(0)).click();
97
- await (await MobileCardCO.getCardContent('215693')).waitForDisplayed();
98
- const snapshot = await browser.checkSnapshot(MobileCardCO.snapshotPath('expandable-multi'));
99
- await expect(snapshot).toEqual(0);
100
- });
101
- });
102
- });
103
- }
@@ -1,42 +0,0 @@
1
- import { PATH_MOBILE_CARD, PATH_E2E_MOBILE_CARD } from '../../paths';
2
- import { PageObject, Urlbuilder } from '../helpers';
3
-
4
- export const knobs = {
5
- allowMultipleOpen: 'knob-allowMultipleOpen',
6
- };
7
- export default class MobileCard extends PageObject {
8
- static withPropsURL = new Urlbuilder(PATH_MOBILE_CARD, 'with-props');
9
-
10
- static expandableTouchableURL = new Urlbuilder(PATH_E2E_MOBILE_CARD, 'expandable-touchable-card');
11
-
12
- static smallHeightURL = new Urlbuilder(PATH_MOBILE_CARD, 'small-height');
13
-
14
- static cardGroupURL = new Urlbuilder(PATH_MOBILE_CARD, 'card-group');
15
-
16
- static expandableURL = new Urlbuilder(PATH_MOBILE_CARD, 'expandable');
17
-
18
- static multiExpandableURL = new Urlbuilder(PATH_MOBILE_CARD, 'multi-expandable');
19
-
20
- static cardGroupNoTitleURL = new Urlbuilder(PATH_MOBILE_CARD, 'card-group-no-title');
21
-
22
- static withDetailsURL = new Urlbuilder(PATH_MOBILE_CARD, 'With-Details-Subtext-And-Props');
23
-
24
- static withIconsURL = new Urlbuilder(PATH_MOBILE_CARD, 'card-with-icons');
25
-
26
- static async expandCard(index) {
27
- return $$('//div[@data-testid="ds-card-expand-chevron"]/span')[index];
28
- }
29
-
30
- static async getCardContent(content) {
31
- return $(`//p[contains(text(), '${content}')]`);
32
- }
33
-
34
- static async getCardTitle() {
35
- return $('[data-testid="card-title"]');
36
- }
37
-
38
- // Snapshots
39
- static snapshotPath(example = 'with-props') {
40
- return PageObject.getSnapshotPathBuilder('MobileCard', example, 'ds-mobile');
41
- }
42
- }