mirror of
https://github.com/ionic-team/ionic-framework.git
synced 2025-08-19 11:41:20 +08:00
test(e2e): update body font family (#16065)
This commit is contained in:
@ -8,4 +8,5 @@
|
|||||||
|
|
||||||
:root {
|
:root {
|
||||||
--ion-font-family: "TestingFont", "Helvetica Neue", sans-serif;
|
--ion-font-family: "TestingFont", "Helvetica Neue", sans-serif;
|
||||||
|
font-family: "TestingFont", "Helvetica Neue", sans-serif;
|
||||||
}
|
}
|
||||||
|
@ -19,7 +19,7 @@ it('action-sheet: alertFromActionSheet', async () => {
|
|||||||
|
|
||||||
const alert = await page.find('ion-alert');
|
const alert = await page.find('ion-alert');
|
||||||
await alert.waitForVisible();
|
await alert.waitForVisible();
|
||||||
await page.waitFor(100);
|
await page.waitFor(250);
|
||||||
|
|
||||||
compare = await page.compareScreenshot(`alert open`);
|
compare = await page.compareScreenshot(`alert open`);
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
@ -18,9 +18,11 @@ it('alert: basic', async () => {
|
|||||||
|
|
||||||
for (const [buttonSelector, message] of alerts) {
|
for (const [buttonSelector, message] of alerts) {
|
||||||
await page.click(buttonSelector);
|
await page.click(buttonSelector);
|
||||||
|
|
||||||
const alert = await page.find('ion-alert');
|
const alert = await page.find('ion-alert');
|
||||||
expect(alert).not.toBe(null);
|
expect(alert).not.toBe(null);
|
||||||
await alert.waitForVisible();
|
await alert.waitForVisible();
|
||||||
|
await page.waitFor(250);
|
||||||
|
|
||||||
const compare = await page.compareScreenshot(message);
|
const compare = await page.compareScreenshot(message);
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
@ -18,10 +18,11 @@ it('alert: standalone', async () => {
|
|||||||
|
|
||||||
for (const [buttonSelector, message] of alerts) {
|
for (const [buttonSelector, message] of alerts) {
|
||||||
await page.click(buttonSelector);
|
await page.click(buttonSelector);
|
||||||
|
|
||||||
const alert = await page.find('ion-alert');
|
const alert = await page.find('ion-alert');
|
||||||
expect(alert).not.toBe(null);
|
expect(alert).not.toBe(null);
|
||||||
await alert.waitForVisible();
|
await alert.waitForVisible();
|
||||||
await page.waitFor(100);
|
await page.waitFor(250);
|
||||||
|
|
||||||
const compare = await page.compareScreenshot(message);
|
const compare = await page.compareScreenshot(message);
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
@ -5,7 +5,7 @@ it('card-header: basic', async () => {
|
|||||||
url: '/src/components/card-header/test/basic?ionic:_testing=true'
|
url: '/src/components/card-header/test/basic?ionic:_testing=true'
|
||||||
});
|
});
|
||||||
|
|
||||||
await page.waitFor(100);
|
await page.waitFor(250);
|
||||||
|
|
||||||
const compare = await page.compareScreenshot();
|
const compare = await page.compareScreenshot();
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
@ -13,7 +13,7 @@ it('datetime: basic', async () => {
|
|||||||
|
|
||||||
const picker = await page.find('ion-picker');
|
const picker = await page.find('ion-picker');
|
||||||
await picker.waitForVisible();
|
await picker.waitForVisible();
|
||||||
await page.waitFor(100);
|
await page.waitFor(250);
|
||||||
|
|
||||||
compare = await page.compareScreenshot('should open custom picker');
|
compare = await page.compareScreenshot('should open custom picker');
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
@ -5,7 +5,7 @@ it('img: basic', async () => {
|
|||||||
url: '/src/components/img/test/basic?ionic:_testing=true'
|
url: '/src/components/img/test/basic?ionic:_testing=true'
|
||||||
});
|
});
|
||||||
|
|
||||||
await page.waitFor(100);
|
await page.waitFor(250);
|
||||||
|
|
||||||
const compare = await page.compareScreenshot();
|
const compare = await page.compareScreenshot();
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
@ -5,7 +5,7 @@ it('img: standalone', async () => {
|
|||||||
url: '/src/components/img/test/standalone?ionic:_testing=true'
|
url: '/src/components/img/test/standalone?ionic:_testing=true'
|
||||||
});
|
});
|
||||||
|
|
||||||
await page.waitFor(100);
|
await page.waitFor(250);
|
||||||
|
|
||||||
const compare = await page.compareScreenshot();
|
const compare = await page.compareScreenshot();
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
@ -6,11 +6,9 @@ it('popover: standalone', async () => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
await page.click('#basic');
|
await page.click('#basic');
|
||||||
const popover = await page.find('ion-popover');
|
const alert = await page.find('ion-popover');
|
||||||
expect(popover).not.toBeNull();
|
await alert.waitForVisible();
|
||||||
|
await page.waitFor(250);
|
||||||
await popover.waitForVisible();
|
|
||||||
await page.waitFor(500);
|
|
||||||
|
|
||||||
const compare = await page.compareScreenshot();
|
const compare = await page.compareScreenshot();
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
@ -5,6 +5,8 @@ it('radio-group: standalone', async () => {
|
|||||||
url: '/src/components/radio-group/test/standalone?ionic:_testing=true'
|
url: '/src/components/radio-group/test/standalone?ionic:_testing=true'
|
||||||
});
|
});
|
||||||
|
|
||||||
|
await page.waitFor(250);
|
||||||
|
|
||||||
const compare = await page.compareScreenshot();
|
const compare = await page.compareScreenshot();
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
});
|
});
|
||||||
|
@ -5,6 +5,8 @@ it('segment: basic', async () => {
|
|||||||
url: '/src/components/segment/test/basic?ionic:_testing=true'
|
url: '/src/components/segment/test/basic?ionic:_testing=true'
|
||||||
});
|
});
|
||||||
|
|
||||||
|
await page.waitFor(250);
|
||||||
|
|
||||||
const compare = await page.compareScreenshot();
|
const compare = await page.compareScreenshot();
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
});
|
});
|
||||||
|
@ -5,6 +5,8 @@ it('segment: modes', async () => {
|
|||||||
url: '/src/components/segment/test/modes?ionic:_testing=true'
|
url: '/src/components/segment/test/modes?ionic:_testing=true'
|
||||||
});
|
});
|
||||||
|
|
||||||
|
await page.waitFor(250);
|
||||||
|
|
||||||
const compare = await page.compareScreenshot();
|
const compare = await page.compareScreenshot();
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
});
|
});
|
||||||
|
@ -5,6 +5,8 @@ it('segment: standalone', async () => {
|
|||||||
url: '/src/components/segment/test/standalone?ionic:_testing=true'
|
url: '/src/components/segment/test/standalone?ionic:_testing=true'
|
||||||
});
|
});
|
||||||
|
|
||||||
|
await page.waitFor(250);
|
||||||
|
|
||||||
const compare = await page.compareScreenshot();
|
const compare = await page.compareScreenshot();
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
});
|
});
|
||||||
|
@ -13,7 +13,7 @@ it('select: basic', async () => {
|
|||||||
|
|
||||||
const alert = await page.find('ion-alert');
|
const alert = await page.find('ion-alert');
|
||||||
await alert.waitForVisible();
|
await alert.waitForVisible();
|
||||||
await page.waitFor(100);
|
await page.waitFor(250);
|
||||||
|
|
||||||
compare = await page.compareScreenshot('should open gender single select');
|
compare = await page.compareScreenshot('should open gender single select');
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
@ -22,10 +22,10 @@ it('select: basic', async () => {
|
|||||||
|
|
||||||
select = await page.find('#customSelect');
|
select = await page.find('#customSelect');
|
||||||
await select.click();
|
await select.click();
|
||||||
await page.waitFor(100);
|
|
||||||
|
|
||||||
const actionSheet = await page.find('ion-action-sheet');
|
const actionSheet = await page.find('ion-action-sheet');
|
||||||
await actionSheet.waitForVisible();
|
await actionSheet.waitForVisible();
|
||||||
|
await page.waitFor(250);
|
||||||
|
|
||||||
compare = await page.compareScreenshot('should open custom action sheet select');
|
compare = await page.compareScreenshot('should open custom action sheet select');
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
@ -13,6 +13,7 @@ it('select: multiple-value', async () => {
|
|||||||
|
|
||||||
const alert = await page.find('ion-alert');
|
const alert = await page.find('ion-alert');
|
||||||
await alert.waitForVisible();
|
await alert.waitForVisible();
|
||||||
|
await page.waitFor(250);
|
||||||
|
|
||||||
compare = await page.compareScreenshot('should open toppings multiple select');
|
compare = await page.compareScreenshot('should open toppings multiple select');
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
@ -13,7 +13,7 @@ it('select: single-value', async () => {
|
|||||||
|
|
||||||
const alert = await page.find('ion-alert');
|
const alert = await page.find('ion-alert');
|
||||||
await alert.waitForVisible();
|
await alert.waitForVisible();
|
||||||
await page.waitFor(100);
|
await page.waitFor(250);
|
||||||
|
|
||||||
compare = await page.compareScreenshot('should open gender single select');
|
compare = await page.compareScreenshot('should open gender single select');
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
@ -10,12 +10,14 @@ it('toast: basic', async () => {
|
|||||||
|
|
||||||
let toast = await page.find('ion-toast');
|
let toast = await page.find('ion-toast');
|
||||||
await toast.waitForVisible();
|
await toast.waitForVisible();
|
||||||
|
await page.waitFor(250);
|
||||||
|
|
||||||
let compare = await page.compareScreenshot();
|
let compare = await page.compareScreenshot();
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
|
||||||
await toast.callMethod('dismiss');
|
await toast.callMethod('dismiss');
|
||||||
await toast.waitForNotVisible();
|
await toast.waitForNotVisible();
|
||||||
|
await page.waitFor(250);
|
||||||
|
|
||||||
compare = await page.compareScreenshot('dismissed');
|
compare = await page.compareScreenshot('dismissed');
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
@ -10,6 +10,7 @@ it('toast: standalone', async () => {
|
|||||||
|
|
||||||
const toast = await page.find('ion-toast');
|
const toast = await page.find('ion-toast');
|
||||||
await toast.waitForVisible();
|
await toast.waitForVisible();
|
||||||
|
await page.waitFor(250);
|
||||||
|
|
||||||
const compare = await page.compareScreenshot();
|
const compare = await page.compareScreenshot();
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
|
@ -5,6 +5,8 @@ it('toggle: basic', async () => {
|
|||||||
url: '/src/components/toggle/test/basic?ionic:_testing=true'
|
url: '/src/components/toggle/test/basic?ionic:_testing=true'
|
||||||
});
|
});
|
||||||
|
|
||||||
|
await page.waitFor(250);
|
||||||
|
|
||||||
const compare = await page.compareScreenshot();
|
const compare = await page.compareScreenshot();
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
});
|
});
|
||||||
|
@ -5,6 +5,8 @@ it('themes: css-variables', async () => {
|
|||||||
url: '/src/themes/test/css-variables?ionic:_testing=true'
|
url: '/src/themes/test/css-variables?ionic:_testing=true'
|
||||||
});
|
});
|
||||||
|
|
||||||
|
await page.waitFor(250);
|
||||||
|
|
||||||
const compare = await page.compareScreenshot();
|
const compare = await page.compareScreenshot();
|
||||||
expect(compare).toMatchScreenshot();
|
expect(compare).toMatchScreenshot();
|
||||||
});
|
});
|
||||||
|
Reference in New Issue
Block a user