dimsum-e2e-tests 3.80.0-next.12 → 3.80.0-next.13
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 +6 -0
- package/ds-apppicker/aria-disabled/DSAppPicker.aria-disabled.visual.spec.js +14 -1
- package/ds-apppicker/basic/DSAppPicker.basic.visual.spec.js +12 -7
- package/ds-pills-v2/DSPillsV2CO.js +53 -1
- package/ds-pills-v2/pitfalls/DSPills.inputPill.func.spec.js +26 -0
- package/ds-pills-v2/pitfalls/DSPills.inputWithFormItemBlockURL.axe-core.func.spec.js +38 -0
- package/ds-pills-v2/pitfalls/DSPills.inputWithFormItemBlockURL.func.spec.js +72 -0
- package/package.json +148 -149
- package/paths.js +2 -47
- package/ds-mobile/Accordion/DSAccordion.visual.spec.js +0 -33
- package/ds-mobile/Accordion/DSAccordionCO.js +0 -37
- package/ds-mobile/CategoryBox/CategoryBox.visual.spec.js +0 -18
- package/ds-mobile/CategoryBox/CategoryBoxCO.js +0 -17
- package/ds-mobile/CollectionBox/CollectionBox.visual.spec.js +0 -16
- package/ds-mobile/CollectionBox/CollectionBoxCO.js +0 -15
- package/ds-mobile/GlobalHeader/DSGlobalHeader.visual.spec.js +0 -55
- package/ds-mobile/GlobalHeader/DSGlobalHeaderCO.js +0 -36
- package/ds-mobile/GroupBox/GroupBox.visual.spec.js +0 -15
- package/ds-mobile/GroupBox/GroupBoxCO.js +0 -15
- package/ds-mobile/InfiniteLoader/InfiniteLoader.func.spec.js +0 -90
- package/ds-mobile/InfiniteLoader/InfiniteLoaderCO.js +0 -29
- package/ds-mobile/MobileActionToolbar/MobileActionToolbar.visual.spec.js +0 -39
- package/ds-mobile/MobileActionToolbar/MobileActionToolbarCO.js +0 -19
- package/ds-mobile/MobileBanner/MobileBanner.visual.spec.js +0 -23
- package/ds-mobile/MobileBanner/MobileBannerCO.js +0 -23
- package/ds-mobile/MobileCard/Card.func.spec.js +0 -38
- package/ds-mobile/MobileCard/Card.visual.spec.js +0 -103
- package/ds-mobile/MobileCard/MobileCardCO.js +0 -42
- package/ds-mobile/MobileContextMenu/MobileContextMenu.func.spec.js +0 -88
- package/ds-mobile/MobileContextMenu/MobileContextMenu.visual.spec.js +0 -31
- package/ds-mobile/MobileContextMenu/MobileContextMenuCO.js +0 -72
- package/ds-mobile/MobileDatePicker/MobileDatePicker.func.spec.js +0 -15
- package/ds-mobile/MobileDatePicker/MobileDatePicker.visual.spec.js +0 -15
- package/ds-mobile/MobileDatePicker/MobileDatePickerCO.js +0 -35
- package/ds-mobile/MobileDropdownMenu/MobileDropdownMenu.func.spec.js +0 -38
- package/ds-mobile/MobileDropdownMenu/MobileDropdownMenu.visual.spec.js +0 -16
- package/ds-mobile/MobileDropdownMenu/MobileDropdownMenuCO.js +0 -37
- package/ds-mobile/MobileEmptyState/MobileEmptyState.visual.spec.js +0 -15
- package/ds-mobile/MobileEmptyState/MobileEmptyStateCO.js +0 -14
- package/ds-mobile/MobileFilterbar/MobileFilterbar.visual.spec.js +0 -39
- package/ds-mobile/MobileFilterbar/MobileFilterbarCO.js +0 -19
- package/ds-mobile/MobileFooter/MobileFooter.func.spec.js +0 -26
- package/ds-mobile/MobileFooter/MobileFooter.visual.spec.js +0 -51
- package/ds-mobile/MobileFooter/MobileFooterCO.js +0 -27
- package/ds-mobile/MobileListItem/MobileListItem.visual.spec.js +0 -56
- package/ds-mobile/MobileListItem/MobileListItemCO.js +0 -19
- package/ds-mobile/MobileLoadingPage/MobileLoadingPage.visual.spec.js +0 -37
- package/ds-mobile/MobileLoadingPage/MobileLoadingPageCO.js +0 -23
- package/ds-mobile/MobilePageHeader/MobilePageHeader.func.spec.js +0 -22
- package/ds-mobile/MobilePageHeader/MobilePageHeader.visual.spec.js +0 -135
- package/ds-mobile/MobilePageHeader/MobilePageHeaderCO.js +0 -67
- package/ds-mobile/MobileSelectList/MobileSelectList.visual.spec.js +0 -56
- package/ds-mobile/MobileSelectList/MobileSelectListCO.js +0 -21
- package/ds-mobile/MobileSeparator/MobileSeparator.visual.spec.js +0 -28
- package/ds-mobile/MobileSeparator/MobileSeparatorCO.js +0 -17
- package/ds-mobile/MobileTimePicker/MobileTimePickerCO.js +0 -41
- package/ds-mobile/Modal/MobileModal.visual.spec.js +0 -56
- package/ds-mobile/Modal/MobileModalCO.js +0 -28
- package/ds-mobile/PageFilter/PageFilter.visual.spec.js +0 -46
- package/ds-mobile/PageFilter/PageFilterCO.js +0 -19
- package/ds-mobile/PageForm/PageForm.visual.spec.js +0 -14
- package/ds-mobile/PageForm/PageFormCO.js +0 -11
- package/ds-mobile/PageList/PageList.visual.spec.js +0 -31
- package/ds-mobile/PageList/PageListCO.js +0 -19
- package/ds-mobile/PageSummary/PageSummary.visual.spec.js +0 -20
- package/ds-mobile/PageSummary/PageSummaryCO.js +0 -11
- package/ds-mobile/SwipeToRefresh/SwipeToRefresh.func.spec.js +0 -26
- package/ds-mobile/SwipeToRefresh/SwipeToRefreshCO.js +0 -20
- package/ds-mobile/Tabs/MobileTabs.visual.spec.js +0 -91
- package/ds-mobile/Tabs/TabsCO.js +0 -37
- package/ds-mobile/Tooltip/MobileTooltip.func.spec.js +0 -17
- package/ds-mobile/Tooltip/MobileTooltip.visual.spec.js +0 -16
- package/ds-mobile/Tooltip/TooltipCO.js +0 -23
- package/ds-mobile/helpers.js +0 -7
|
@@ -1,28 +0,0 @@
|
|
|
1
|
-
/* eslint-disable import/no-relative-packages */
|
|
2
|
-
import { PATH_MOBILE_MODAL } from '../../paths';
|
|
3
|
-
import { PageObject, Urlbuilder } from '../helpers';
|
|
4
|
-
|
|
5
|
-
export default class ModalMobile extends PageObject {
|
|
6
|
-
static basicURL = new Urlbuilder(PATH_MOBILE_MODAL, 'basic');
|
|
7
|
-
|
|
8
|
-
static truncatedURL = new Urlbuilder(PATH_MOBILE_MODAL, 'truncated');
|
|
9
|
-
|
|
10
|
-
static customContent = new Urlbuilder(PATH_MOBILE_MODAL, 'custom-content');
|
|
11
|
-
|
|
12
|
-
static async getOpenModal() {
|
|
13
|
-
return $('[data-testid="ds-button"]');
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
static async getTitle() {
|
|
17
|
-
return $('div*=Title');
|
|
18
|
-
}
|
|
19
|
-
|
|
20
|
-
static async getCustomTitle() {
|
|
21
|
-
return $('h2*=This is a custom title');
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
// Snapshots
|
|
25
|
-
static snapshotPath(example = 'basic') {
|
|
26
|
-
return PageObject.getSnapshotPathBuilder('MobileModal', example, 'ds-mobile');
|
|
27
|
-
}
|
|
28
|
-
}
|
|
@@ -1,46 +0,0 @@
|
|
|
1
|
-
import PageFilterCO from './PageFilterCO';
|
|
2
|
-
|
|
3
|
-
if (browser.capabilities['ice:options'].isPhone) {
|
|
4
|
-
describe('PUI-4408 - MobilePageFilter:: visual test', () => {
|
|
5
|
-
describe('MobilePageFilter, with left button', () => {
|
|
6
|
-
before('loading page', async () => {
|
|
7
|
-
const errorOnGo = await PageFilterCO.leftButtonURL.go();
|
|
8
|
-
if (errorOnGo) throw errorOnGo;
|
|
9
|
-
});
|
|
10
|
-
it('should display page filter with left button', async () => {
|
|
11
|
-
const snapshot = await browser.checkSnapshot(PageFilterCO.snapshotPath('left-button'));
|
|
12
|
-
await expect(snapshot).toEqual(0);
|
|
13
|
-
});
|
|
14
|
-
});
|
|
15
|
-
describe('MobilePageFilter, with right button', () => {
|
|
16
|
-
before('loading page', async () => {
|
|
17
|
-
const errorOnGo = await PageFilterCO.rightButtonURL.go();
|
|
18
|
-
if (errorOnGo) throw errorOnGo;
|
|
19
|
-
});
|
|
20
|
-
it('should display page filter with right button', async () => {
|
|
21
|
-
const snapshot = await browser.checkSnapshot(PageFilterCO.snapshotPath('right-button'));
|
|
22
|
-
await expect(snapshot).toEqual(0);
|
|
23
|
-
});
|
|
24
|
-
});
|
|
25
|
-
describe('MobilePageFilter, with footer', () => {
|
|
26
|
-
before('loading page', async () => {
|
|
27
|
-
const errorOnGo = await PageFilterCO.withFooterURL.go();
|
|
28
|
-
if (errorOnGo) throw errorOnGo;
|
|
29
|
-
});
|
|
30
|
-
it('should display page filter with footer', async () => {
|
|
31
|
-
const snapshot = await browser.checkSnapshot(PageFilterCO.snapshotPath('with-footer'));
|
|
32
|
-
await expect(snapshot).toEqual(0);
|
|
33
|
-
});
|
|
34
|
-
});
|
|
35
|
-
describe('MobilePageFilter, with breadcrumb', () => {
|
|
36
|
-
before('loading page', async () => {
|
|
37
|
-
const errorOnGo = await PageFilterCO.breadcrumbURL.go();
|
|
38
|
-
if (errorOnGo) throw errorOnGo;
|
|
39
|
-
});
|
|
40
|
-
it('should display page filter with breadcrumb', async () => {
|
|
41
|
-
const snapshot = await browser.checkSnapshot(PageFilterCO.snapshotPath('with breadcrum'));
|
|
42
|
-
await expect(snapshot).toEqual(0);
|
|
43
|
-
});
|
|
44
|
-
});
|
|
45
|
-
});
|
|
46
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { PATH_MOBILE_PAGE_FILTER } from '../../paths';
|
|
2
|
-
import { PageObject, Urlbuilder } from '../helpers';
|
|
3
|
-
|
|
4
|
-
export default class PageFilter extends PageObject {
|
|
5
|
-
static basicURL = new Urlbuilder(PATH_MOBILE_PAGE_FILTER, 'basic');
|
|
6
|
-
|
|
7
|
-
static leftButtonURL = new Urlbuilder(PATH_MOBILE_PAGE_FILTER, 'with-left-button');
|
|
8
|
-
|
|
9
|
-
static rightButtonURL = new Urlbuilder(PATH_MOBILE_PAGE_FILTER, 'with-right-button');
|
|
10
|
-
|
|
11
|
-
static withFooterURL = new Urlbuilder(PATH_MOBILE_PAGE_FILTER, 'with-footer');
|
|
12
|
-
|
|
13
|
-
static breadcrumbURL = new Urlbuilder(PATH_MOBILE_PAGE_FILTER, 'breadcrumb');
|
|
14
|
-
|
|
15
|
-
// Snapshots
|
|
16
|
-
static snapshotPath(example = 'basic') {
|
|
17
|
-
return PageObject.getSnapshotPathBuilder('PageFilter', example, 'ds-mobile');
|
|
18
|
-
}
|
|
19
|
-
}
|
|
@@ -1,14 +0,0 @@
|
|
|
1
|
-
import PageFormCO from './PageFormCO';
|
|
2
|
-
|
|
3
|
-
if (browser.capabilities['ice:options'].isPhone) {
|
|
4
|
-
describe('PUI-3087 - PageForm - visual test portrait', () => {
|
|
5
|
-
before('loading page', async () => {
|
|
6
|
-
const errorOnGo = await PageFormCO.basicURL.go();
|
|
7
|
-
if (errorOnGo) throw errorOnGo;
|
|
8
|
-
});
|
|
9
|
-
it('check visual portrait', async () => {
|
|
10
|
-
const snapshot = await browser.checkSnapshot(PageFormCO.snapshotPath());
|
|
11
|
-
await expect(snapshot).toEqual(0);
|
|
12
|
-
});
|
|
13
|
-
});
|
|
14
|
-
}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { PATH_MOBILE_PAGE_FORM } from '../../paths';
|
|
2
|
-
import { PageObject, Urlbuilder } from '../helpers';
|
|
3
|
-
|
|
4
|
-
export default class PageForm extends PageObject {
|
|
5
|
-
static basicURL = new Urlbuilder(PATH_MOBILE_PAGE_FORM, 'basic');
|
|
6
|
-
|
|
7
|
-
// Snapshots
|
|
8
|
-
static snapshotPath(example = 'basic') {
|
|
9
|
-
return PageObject.getSnapshotPathBuilder('PageForm', example, 'ds-mobile');
|
|
10
|
-
}
|
|
11
|
-
}
|
|
@@ -1,31 +0,0 @@
|
|
|
1
|
-
/* eslint-disable wdio/no-pause */
|
|
2
|
-
import PageListCO from './PageListCO';
|
|
3
|
-
|
|
4
|
-
if (browser.capabilities['ice:options'].isPhone) {
|
|
5
|
-
describe('PUI-4512 - PageList - truncation rules on PageHeader', () => {
|
|
6
|
-
before('loading page', async () => {
|
|
7
|
-
const errorOnGo = await PageListCO.pageList.go();
|
|
8
|
-
if (errorOnGo) throw errorOnGo;
|
|
9
|
-
});
|
|
10
|
-
it('should display title correctly', async () => {
|
|
11
|
-
await browser.eyesOpen();
|
|
12
|
-
await (await PageListCO.getTitle()).waitForDisplayed();
|
|
13
|
-
await (await PageListCO.getTitle()).click();
|
|
14
|
-
await browser.pause(300);
|
|
15
|
-
const snapshot = await browser.eyesCheckSnapshot(PageListCO.snapshotPath('truncation-page-list'));
|
|
16
|
-
await expect(snapshot).toEqual(0);
|
|
17
|
-
});
|
|
18
|
-
});
|
|
19
|
-
|
|
20
|
-
describe('PUI-9149 - PageList - without filterbar -visual', () => {
|
|
21
|
-
before('loading page', async () => {
|
|
22
|
-
const errorOnGo = await PageListCO.withoutFilterbar.go();
|
|
23
|
-
if (errorOnGo) throw errorOnGo;
|
|
24
|
-
});
|
|
25
|
-
it('should display page list without filterbar', async () => {
|
|
26
|
-
await browser.eyesOpen();
|
|
27
|
-
const snapshot = await browser.eyesCheckSnapshot(PageListCO.snapshotPath('mobile-pagelist-nofilterbar'));
|
|
28
|
-
await expect(snapshot).toEqual(0);
|
|
29
|
-
});
|
|
30
|
-
});
|
|
31
|
-
}
|
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import { PATH_MOBILE_PAGE_LIST, PATH_E2E_MOBILE_PAGELIST } from '../../paths';
|
|
2
|
-
import { PageObject, Urlbuilder } from '../helpers';
|
|
3
|
-
|
|
4
|
-
export default class PageList extends PageObject {
|
|
5
|
-
static basicURL = new Urlbuilder(PATH_MOBILE_PAGE_LIST, 'basic');
|
|
6
|
-
|
|
7
|
-
static withoutFilterbar = new Urlbuilder(PATH_E2E_MOBILE_PAGELIST, 'without-filterbar');
|
|
8
|
-
|
|
9
|
-
static pageList = new Urlbuilder(PATH_MOBILE_PAGE_LIST, 'page-list-example');
|
|
10
|
-
|
|
11
|
-
static async getTitle() {
|
|
12
|
-
return $('span*=pageTitle');
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
// Snapshots
|
|
16
|
-
static snapshotPath(example = 'basic') {
|
|
17
|
-
return PageObject.getSnapshotPathBuilder('PageList', example, 'ds-mobile');
|
|
18
|
-
}
|
|
19
|
-
}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
import PageSummaryCO from './PageSummaryCO';
|
|
2
|
-
|
|
3
|
-
if (browser.capabilities['ice:options'].isPhone) {
|
|
4
|
-
describe('PUI-3115 - PageSummary', () => {
|
|
5
|
-
beforeEach('loading page', async () => {
|
|
6
|
-
const errorOnGo = await PageSummaryCO.basicURL.go();
|
|
7
|
-
if (errorOnGo) throw errorOnGo;
|
|
8
|
-
});
|
|
9
|
-
it('check visual portrait', async () => {
|
|
10
|
-
const snapshot = await browser.checkSnapshot(PageSummaryCO.snapshotPath('portrait'));
|
|
11
|
-
await expect(snapshot).toEqual(0);
|
|
12
|
-
});
|
|
13
|
-
|
|
14
|
-
it('check visual landscape', async () => {
|
|
15
|
-
await browser.setOrientation('LANDSCAPE');
|
|
16
|
-
const snapshot = await browser.checkSnapshot(PageSummaryCO.snapshotPath('landscape'));
|
|
17
|
-
await expect(snapshot).toEqual(0);
|
|
18
|
-
});
|
|
19
|
-
});
|
|
20
|
-
}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import { PATH_MOBILE_PAGE_SUMMARY } from '../../paths';
|
|
2
|
-
import { PageObject, Urlbuilder } from '../helpers';
|
|
3
|
-
|
|
4
|
-
export default class PageSummary extends PageObject {
|
|
5
|
-
static basicURL = new Urlbuilder(PATH_MOBILE_PAGE_SUMMARY, 'basic');
|
|
6
|
-
|
|
7
|
-
// Snapshots
|
|
8
|
-
static snapshotPath(example = 'basic') {
|
|
9
|
-
return PageObject.getSnapshotPathBuilder('PageSummary', example, 'ds-mobile');
|
|
10
|
-
}
|
|
11
|
-
}
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import SwipeToRefresh from './SwipeToRefreshCO';
|
|
2
|
-
import Gestures from '../../gestures';
|
|
3
|
-
|
|
4
|
-
if (browser.capabilities['ice:options'].isPhone) {
|
|
5
|
-
describe('PUI-4329 - SwipeToRefresh - display loader', () => {
|
|
6
|
-
beforeEach('loading page', async () => {
|
|
7
|
-
const errorOnGo = await SwipeToRefresh.withMobileCards.go();
|
|
8
|
-
if (errorOnGo) throw errorOnGo;
|
|
9
|
-
});
|
|
10
|
-
it('should display loader when swipe down', async () => {
|
|
11
|
-
await (await SwipeToRefresh.getCardTitle(0)).waitForDisplayed();
|
|
12
|
-
await Gestures.swipeDown();
|
|
13
|
-
const loaderBox = await SwipeToRefresh.getLoaderBox();
|
|
14
|
-
await expect(loaderBox).toBeDisplayedInViewport();
|
|
15
|
-
});
|
|
16
|
-
});
|
|
17
|
-
describe('PUI-4439 - SwipeToRefresh - refresh only on the top', () => {
|
|
18
|
-
it('should not display loader when is not on the top', async () => {
|
|
19
|
-
await (await SwipeToRefresh.getCardTitle(0)).waitForDisplayed();
|
|
20
|
-
await (await SwipeToRefresh.getCardTitle(15)).scrollIntoView();
|
|
21
|
-
await Gestures.swipeDown();
|
|
22
|
-
const loaderBox = await SwipeToRefresh.getLoaderBox();
|
|
23
|
-
await expect(loaderBox).not.toBeDisplayedInViewport();
|
|
24
|
-
});
|
|
25
|
-
});
|
|
26
|
-
}
|
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
// eslint-disable-next-line import/no-unresolved
|
|
2
|
-
import { PATH_MOBILE_SWIPE_TO_REFRESH } from '../../paths';
|
|
3
|
-
import { PageObject, Urlbuilder } from '../helpers';
|
|
4
|
-
|
|
5
|
-
export default class SwipeToRefresh extends PageObject {
|
|
6
|
-
static withMobileCards = new Urlbuilder(PATH_MOBILE_SWIPE_TO_REFRESH, 'with-mobile-cards');
|
|
7
|
-
|
|
8
|
-
static async getCardTitle(index) {
|
|
9
|
-
return $$('[data-testid="card-title"]')[index];
|
|
10
|
-
}
|
|
11
|
-
|
|
12
|
-
static async getLoaderBox() {
|
|
13
|
-
return $('[data-testid="loader-box"]');
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
// Snapshots
|
|
17
|
-
static snapshotPath(example = 'basic') {
|
|
18
|
-
return PageObject.getSnapshotPathBuilder('SwipeToRefresh', example, 'ds-mobile');
|
|
19
|
-
}
|
|
20
|
-
}
|
|
@@ -1,91 +0,0 @@
|
|
|
1
|
-
import TabsCO from './TabsCO';
|
|
2
|
-
import Gestures, { REL_SWIPE_DIRECTION } from '../../gestures';
|
|
3
|
-
|
|
4
|
-
if (browser.capabilities['ice:options'].isPhone) {
|
|
5
|
-
describe('PUI-3080 - Mobile Tabs - visual tests', () => {
|
|
6
|
-
describe('Mobile Tabs, tab1 active', () => {
|
|
7
|
-
before('loading page', async () => {
|
|
8
|
-
const errorOnGo = await TabsCO.basicURL.go();
|
|
9
|
-
if (errorOnGo) throw errorOnGo;
|
|
10
|
-
});
|
|
11
|
-
it('check simple render', async () => {
|
|
12
|
-
const tab = await TabsCO.getTab1();
|
|
13
|
-
await expect(tab).toBeDisplayed();
|
|
14
|
-
const snapshot = await browser.checkSnapshot(TabsCO.snapshotPath('active-tab1'));
|
|
15
|
-
await expect(snapshot).toEqual(0);
|
|
16
|
-
});
|
|
17
|
-
});
|
|
18
|
-
describe('Mobile Tabs, tab2 active', () => {
|
|
19
|
-
before('loading page', async () => {
|
|
20
|
-
const errorOnGo = await TabsCO.secondTabURL.go();
|
|
21
|
-
if (errorOnGo) throw errorOnGo;
|
|
22
|
-
});
|
|
23
|
-
it('move to second tab', async () => {
|
|
24
|
-
const tab = await TabsCO.getTab2();
|
|
25
|
-
await expect(tab).toBeDisplayed();
|
|
26
|
-
const snapshot = await browser.checkSnapshot(TabsCO.snapshotPath('active-tab2'));
|
|
27
|
-
await expect(snapshot).toEqual(0);
|
|
28
|
-
});
|
|
29
|
-
});
|
|
30
|
-
describe('Mobile Tabs, move to first tab', () => {
|
|
31
|
-
before('loading page', async () => {
|
|
32
|
-
const errorOnGo = await TabsCO.secondTabURL.go();
|
|
33
|
-
if (errorOnGo) throw errorOnGo;
|
|
34
|
-
});
|
|
35
|
-
it('move to first tab', async () => {
|
|
36
|
-
const tab2 = await TabsCO.getTab2();
|
|
37
|
-
await expect(tab2).toBeDisplayed();
|
|
38
|
-
await (await TabsCO.getTab1()).click();
|
|
39
|
-
const tab1 = await TabsCO.getTab1();
|
|
40
|
-
await expect(tab1).toBeDisplayed();
|
|
41
|
-
const snapshot = await browser.checkSnapshot(TabsCO.snapshotPath('move-to-again-first-tab'));
|
|
42
|
-
await expect(snapshot).toEqual(0);
|
|
43
|
-
});
|
|
44
|
-
});
|
|
45
|
-
|
|
46
|
-
describe('PUI-5703 - Mobile Tabs, flexible', () => {
|
|
47
|
-
before('loading page', async () => {
|
|
48
|
-
const errorOnGo = await TabsCO.mobileFlexible.go();
|
|
49
|
-
if (errorOnGo) throw errorOnGo;
|
|
50
|
-
});
|
|
51
|
-
it('should display gradient', async () => {
|
|
52
|
-
const tab = await TabsCO.getTab2();
|
|
53
|
-
await expect(tab).toBeDisplayed();
|
|
54
|
-
await (await TabsCO.getTab1()).waitForDisplayed({ timeout: 5000 });
|
|
55
|
-
const snapshot = await browser.checkSnapshot(TabsCO.snapshotPath('mobile-flexible'));
|
|
56
|
-
await expect(snapshot).toEqual(0);
|
|
57
|
-
});
|
|
58
|
-
});
|
|
59
|
-
describe('PUI-8351 - Mobile Tabs, flexible', () => {
|
|
60
|
-
before('loading page', async () => {
|
|
61
|
-
const errorOnGo = await TabsCO.mobileFixed.go();
|
|
62
|
-
if (errorOnGo) throw errorOnGo;
|
|
63
|
-
});
|
|
64
|
-
it('should display fixed tabs with equal width populating the full viewport width', async () => {
|
|
65
|
-
const snapshot = await browser.checkSnapshot(TabsCO.snapshotPath('mobile-fixed'));
|
|
66
|
-
await expect(snapshot).toEqual(0);
|
|
67
|
-
});
|
|
68
|
-
});
|
|
69
|
-
});
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
if (driver.isAndroid) {
|
|
73
|
-
describe('PUI-5948 - MobileTabs - Right margin at the end of the tabs - Visual Test', () => {
|
|
74
|
-
before('loading page', async () => {
|
|
75
|
-
const errorOnGo = await TabsCO.mobileFlexible.go();
|
|
76
|
-
if (errorOnGo) throw errorOnGo;
|
|
77
|
-
});
|
|
78
|
-
it('should display the right margin when reaching the end', async () => {
|
|
79
|
-
const tabList = await TabsCO.getTabList();
|
|
80
|
-
const targetTab = await TabsCO.getTab(6);
|
|
81
|
-
await Gestures.swipeUntilDisplayed({
|
|
82
|
-
swipeElement: tabList,
|
|
83
|
-
targetElement: targetTab,
|
|
84
|
-
swipeDirection: REL_SWIPE_DIRECTION.left,
|
|
85
|
-
extraSwipes: 2,
|
|
86
|
-
});
|
|
87
|
-
const snapshot = await browser.checkSnapshot(TabsCO.snapshotPath('mobile-flexible-right-margin'));
|
|
88
|
-
await expect(snapshot).toEqual(0);
|
|
89
|
-
});
|
|
90
|
-
});
|
|
91
|
-
}
|
package/ds-mobile/Tabs/TabsCO.js
DELETED
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import { PATH_MOBILE_TABS } from '../../paths';
|
|
2
|
-
import { PageObject, Urlbuilder } from '../helpers';
|
|
3
|
-
|
|
4
|
-
export default class Tabs extends PageObject {
|
|
5
|
-
static basicURL = new Urlbuilder(PATH_MOBILE_TABS, 'basic');
|
|
6
|
-
|
|
7
|
-
static secondTabURL = new Urlbuilder(PATH_MOBILE_TABS, 'second-tab-active');
|
|
8
|
-
|
|
9
|
-
static mobileFlexible = new Urlbuilder(PATH_MOBILE_TABS, 'flexible-tabs');
|
|
10
|
-
|
|
11
|
-
static mobileFixed = new Urlbuilder(PATH_MOBILE_TABS, 'fixed-tabs');
|
|
12
|
-
|
|
13
|
-
static async getTab1() {
|
|
14
|
-
return $('#tab1-label');
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
static async getTab2() {
|
|
18
|
-
return $('#tab2-label');
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
static async getTab(tab = 0) {
|
|
22
|
-
return $(`#tab${tab}-label`);
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
static async getTabList() {
|
|
26
|
-
return $('[data-testid="tab-list"]');
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
static async tabTextContent(text) {
|
|
30
|
-
return $(`span*=${text}`);
|
|
31
|
-
}
|
|
32
|
-
|
|
33
|
-
// Snapshots
|
|
34
|
-
static snapshotPath(example = 'basic') {
|
|
35
|
-
return PageObject.getSnapshotPathBuilder('Tabs', example, 'ds-mobile');
|
|
36
|
-
}
|
|
37
|
-
}
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import TooltipCO from './TooltipCO';
|
|
2
|
-
|
|
3
|
-
if (browser.capabilities['ice:options'].isPhone) {
|
|
4
|
-
describe('PUI-6084 - MobileTooltip, Tap to close', () => {
|
|
5
|
-
before('loading page', async () => {
|
|
6
|
-
const errorOnGo = await TooltipCO.basicURL.go();
|
|
7
|
-
if (errorOnGo) throw errorOnGo;
|
|
8
|
-
});
|
|
9
|
-
it('should close the tooltip', async () => {
|
|
10
|
-
await (await TooltipCO.getLeftIconButton()).click();
|
|
11
|
-
const tooltip = await TooltipCO.getTooltipWrapper();
|
|
12
|
-
await tooltip.waitForDisplayed({ timeout: 2000 });
|
|
13
|
-
await (await TooltipCO.getRightIconButton()).click();
|
|
14
|
-
await expect(tooltip).not.toBeDisplayed();
|
|
15
|
-
});
|
|
16
|
-
});
|
|
17
|
-
}
|
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import TooltipCO from './TooltipCO';
|
|
2
|
-
|
|
3
|
-
if (browser.capabilities['ice:options'].isPhone) {
|
|
4
|
-
describe('PUI-6083 - MobileTooltip, Tooltip - Visual Test', () => {
|
|
5
|
-
before('loading page', async () => {
|
|
6
|
-
const errorOnGo = await TooltipCO.basicURL.go();
|
|
7
|
-
if (errorOnGo) throw errorOnGo;
|
|
8
|
-
});
|
|
9
|
-
it('should display tooltip', async () => {
|
|
10
|
-
await (await TooltipCO.getLeftIconButton()).click();
|
|
11
|
-
await (await TooltipCO.getTooltipWrapper()).waitForDisplayed({ timeout: 2000 });
|
|
12
|
-
const snapshot = await browser.checkSnapshot(TooltipCO.snapshotPath('tooltip'));
|
|
13
|
-
await expect(snapshot).toEqual(0);
|
|
14
|
-
});
|
|
15
|
-
});
|
|
16
|
-
}
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import { PATH_MOBILE_TOOLTIP } from '../../paths';
|
|
2
|
-
import { PageObject, Urlbuilder } from '../helpers';
|
|
3
|
-
|
|
4
|
-
export default class TooltipCO extends PageObject {
|
|
5
|
-
static basicURL = new Urlbuilder(PATH_MOBILE_TOOLTIP, 'basic');
|
|
6
|
-
|
|
7
|
-
static async getTooltipWrapper() {
|
|
8
|
-
return $('[data-testid="ds-tooltip-v3-tooltip-text-wrapper"]');
|
|
9
|
-
}
|
|
10
|
-
|
|
11
|
-
static async getLeftIconButton() {
|
|
12
|
-
return $('[data-testid="left-icon-button"]');
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
static async getRightIconButton() {
|
|
16
|
-
return $('[data-testid="right-icon-button"]');
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
// Snapshots
|
|
20
|
-
static snapshotPath(example = 'basic') {
|
|
21
|
-
return PageObject.getSnapshotPathBuilder('MobileTooltip', example, 'ds-mobile');
|
|
22
|
-
}
|
|
23
|
-
}
|