Skip to content

Commit

Permalink
CR
Browse files Browse the repository at this point in the history
  • Loading branch information
OS-pedrolourenco committed Jan 16, 2025
1 parent 9b2bcda commit 522aafa
Show file tree
Hide file tree
Showing 7 changed files with 22 additions and 5 deletions.
27 changes: 22 additions & 5 deletions core/src/components/tab-bar/test/expand/tab-bar.e2e.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,35 +10,52 @@ configs({ directions: ['ltr'], modes: ['ionic-md'] }).forEach(({ title, screensh
test('should not have visual regressions', async ({ page }) => {
await page.setContent(
`
<style>
.container {
padding: 20px 10px;
}
</style>
<ion-content>
<ion-tab-bar expand="full"/>
<div class="container">
<ion-tab-bar expand="full"/>
</div>
</ion-content>
`,
config
);

// Used the `ion-content` element to take the screenshot because the `ion-tab-bar`element would not be visible otherwise
const content = page.locator('ion-content');
const container = page.locator('.container');

await expect(content).toHaveScreenshot(screenshot(`tab-bar-expand-full`));
await expect(container).toHaveScreenshot(screenshot(`tab-bar-expand-full`));
});
});

test.describe(title('compact'), () => {
test('should not have visual regressions', async ({ page }) => {
await page.setContent(
`
<style>
.container {
width: 55px;
height: 95px;
}
</style>
<ion-content>
<div class="container">
<ion-tab-bar expand="compact"/>
</div>
</ion-content>
`,
config
);

// Used the `ion-content` element to take the screenshot because the `ion-tab-bar` element would not be visible otherwise
const content = page.locator('ion-content');
const container = page.locator('.container');

await expect(content).toHaveScreenshot(screenshot(`tab-bar-expand-compact`));
await expect(container).toHaveScreenshot(screenshot(`tab-bar-expand-compact`));
});
});
});
Expand Down
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.

0 comments on commit 522aafa

Please sign in to comment.