-
Notifications
You must be signed in to change notification settings - Fork 13.4k
Closed
Labels
package: core@ionic/core package@ionic/core packagetype: feature requesta new feature, enhancement, or improvementa new feature, enhancement, or improvement
Description
Feature Request
Ionic version:
[x] 4.x
Describe the Feature Request
Update our e2e tests (specifically overlay components) to take screenshots of more examples.
Describe Preferred Solution
The action sheet splits all of the tests into multiple files:
However, alert loops through each button id to take the screenshots:
test('alert: basic', async () => {
const page = await newE2EPage({
url: '/src/components/alert/test/basic?ionic:_testing=true'
});
const alerts = [
['#basic'],
['#longMessage', 'long message'],
['#multipleButtons', 'multiple buttons'],
['#noMessage', 'no message'],
['#confirm', 'confirm'],
['#prompt', 'prompt'],
['#radio', 'radio'],
['#checkbox', 'checkbox']
];
for (const [buttonSelector, message] of alerts) {
await page.click(buttonSelector);
const alert = await page.find('ion-alert');
expect(alert).not.toBe(null);
await alert.waitForVisible();
await page.waitFor(250);
const compare = await page.compareScreenshot(message);
expect(compare).toMatchScreenshot();
await alert.callMethod('dismiss');
}
});
Meanwhile other components, such as loading aren't taking screenshots of anything but the basic one. I think we should be consistent here, and update the e2e tests for all of the overlay components to the same style:
- Action Sheet
- Alert
- Loading
- Menu
- Modal
- Picker
- Popover
- Toast
Metadata
Metadata
Assignees
Labels
package: core@ionic/core package@ionic/core packagetype: feature requesta new feature, enhancement, or improvementa new feature, enhancement, or improvement