-
Notifications
You must be signed in to change notification settings - Fork 80
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
a4f0adc
commit 1a904e6
Showing
75 changed files
with
352 additions
and
194 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes
File renamed without changes
16 changes: 16 additions & 0 deletions
16
apps/core/tests/visual-regression/components/badge.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { expect, test } from '@playwright/test'; | ||
|
||
import routes from '~/tests/routes'; | ||
|
||
test('badge with icon', async ({ page }) => { | ||
// Arrange | ||
await page.goto(routes.SAMPLE_ABLE_BREWING_SYSTEM); | ||
await page.getByRole('heading', { level: 1, name: '[Sample] Able Brewing System' }).waitFor(); | ||
await page.getByRole('button', { name: 'Add to Cart' }).click(); | ||
|
||
// Act | ||
const badge = page.getByRole('link', { name: 'Cart Items 1' }); | ||
|
||
// Assert | ||
await expect(badge).toHaveScreenshot(); | ||
}); |
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes
File renamed without changes
File renamed without changes
3 changes: 3 additions & 0 deletions
3
...sion/packages/components/carousel.spec.ts → ...al-regression/components/carousel.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,17 @@ | ||
import { expect, test } from '@playwright/test'; | ||
|
||
test('Carousel', async ({ page }) => { | ||
// Arrange | ||
await page.goto('/'); | ||
|
||
// Act | ||
const slides = page | ||
.getByRole('region') | ||
.filter({ has: page.getByRole('heading', { name: 'Featured products' }) }) | ||
.getByRole('tablist', { name: 'Slides' }); | ||
|
||
await slides.scrollIntoViewIfNeeded(); | ||
|
||
// Assert | ||
await expect(slides).toHaveScreenshot(); | ||
}); |
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes
16 changes: 16 additions & 0 deletions
16
apps/core/tests/visual-regression/components/counter.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { expect, test } from '@playwright/test'; | ||
|
||
import routes from '~/tests/routes'; | ||
|
||
test('Counter default', async ({ page }) => { | ||
// Arrange | ||
await page.goto(routes.QUICK_ADD_77); | ||
|
||
// Act | ||
const spinButton = page.getByRole('spinbutton', { name: 'Number' }); | ||
|
||
await spinButton.waitFor(); | ||
|
||
// Assert | ||
await expect(spinButton).toHaveScreenshot(); | ||
}); |
File renamed without changes
16 changes: 16 additions & 0 deletions
16
apps/core/tests/visual-regression/components/datepicker.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { expect, test } from '@playwright/test'; | ||
|
||
import routes from '~/tests/routes'; | ||
|
||
test('Date picker', async ({ page }) => { | ||
// Arrange | ||
await page.goto(routes.QUICK_ADD_77); | ||
|
||
// Act | ||
const datePicker = page.getByRole('dialog').getByPlaceholder('MM/DD/YYYY'); | ||
|
||
await datePicker.waitFor(); | ||
|
||
// Assert | ||
await expect(datePicker).toHaveScreenshot(); | ||
}); |
File renamed without changes
14 changes: 14 additions & 0 deletions
14
apps/core/tests/visual-regression/components/footer.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import { expect, test } from '@playwright/test'; | ||
|
||
test('Footer', async ({ page }) => { | ||
// Arrange | ||
await page.goto('/'); | ||
|
||
// Act | ||
const footer = page.locator('section').filter({ hasText: 'CategoriesShop' }); | ||
|
||
await footer.waitFor(); | ||
|
||
// Assert | ||
await expect(footer).toHaveScreenshot(); | ||
}); |
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { expect, test } from '@playwright/test'; | ||
|
||
import routes from '~/tests/routes'; | ||
|
||
test('Form', async ({ page }) => { | ||
// Arrange | ||
await page.goto(routes.CONTACT_US); | ||
|
||
// Act | ||
const form = page.getByRole('heading', { name: 'Contact Us' }); | ||
|
||
await form.waitFor(); | ||
|
||
// Assert | ||
await expect(form.locator('..').locator('..')).toHaveScreenshot(); | ||
}); |
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes
File renamed without changes
16 changes: 16 additions & 0 deletions
16
apps/core/tests/visual-regression/components/label.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
import { expect, test } from '@playwright/test'; | ||
|
||
import routes from '~/tests/routes'; | ||
|
||
test('Label with input', async ({ page }) => { | ||
// Arrange | ||
await page.goto(routes.LOGIN); | ||
|
||
// Act | ||
const label = page.getByText('Password', { exact: true }); | ||
|
||
await label.waitFor(); | ||
|
||
// Assert | ||
await expect(label.locator('..').locator('..')).toHaveScreenshot(); | ||
}); |
File renamed without changes
14 changes: 14 additions & 0 deletions
14
apps/core/tests/visual-regression/components/navigation-menu.spec.ts
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
import { expect, test } from '@playwright/test'; | ||
|
||
test('Navigation menu', async ({ page }) => { | ||
// Arrange | ||
await page.goto('/'); | ||
|
||
// Act | ||
const navigation = page.getByRole('navigation', { name: 'Main' }); | ||
|
||
await navigation.waitFor(); | ||
|
||
// Assert | ||
await expect(navigation).toHaveScreenshot(); | ||
}); |
File renamed without changes
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes
Oops, something went wrong.