-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fix issue with next button on mobile
- Loading branch information
1 parent
aee3543
commit a700d87
Showing
5 changed files
with
86 additions
and
80 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
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,68 @@ | ||
import { expect, test } from '@playwright/test' | ||
|
||
// Group tests with specific settings | ||
test.describe('Desktop Tests', () => { | ||
test.use({ | ||
viewport: { | ||
height: 700, | ||
width: 1200, | ||
}, | ||
}) | ||
|
||
test('test stet', async ({ page }) => { | ||
await page.goto('http://localhost:8001/stet') | ||
await page.getByLabel('English en').check() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByText('Cebuano').click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByRole('button', { name: 'Generate File' }).click() | ||
}) | ||
|
||
test('test stet 2', async ({ page }) => { | ||
await page.goto('http://localhost:8001/stet') | ||
await page.getByText('English').click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByRole('button', { name: 'Back' }).click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByText('Bichelamar (Bislama)').click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByRole('link', { name: 'Target Language' }).click() | ||
await page.getByRole('link', { name: 'Source Language' }).click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByRole('button', { name: 'Back' }).click() | ||
await page.getByRole('button', { name: 'Back' }).click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByRole('button', { name: 'Edit' }).click() | ||
await page.getByRole('button', { name: 'Edit' }).click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByLabel('Email me a copy of my').check() | ||
await page.getByPlaceholder('Type email address here (').click() | ||
await page.getByPlaceholder('Type email address here (').fill('[email protected]') | ||
await page.getByRole('button', { name: 'Submit' }).click() | ||
await page.getByRole('button', { name: 'Generate File' }).click() | ||
}) | ||
}) | ||
|
||
// Separate group for mobile tests | ||
test.describe('Mobile Tests', () => { | ||
test.use({ | ||
viewport: { | ||
height: 600, | ||
width: 300, | ||
}, | ||
}) | ||
|
||
test('test mobile', async ({ page }) => { | ||
await page.goto('http://localhost:8001/stet') | ||
await page.goto('http://localhost:8001/stet/source_languages') | ||
await page.getByLabel('English en').check() | ||
await page.getByRole('button').nth(1).click() | ||
await page.getByText('Bahasa Indonesia (Indonesian)').click() | ||
await page.getByRole('button').nth(1).click() | ||
await page.getByRole('button', { name: '2' }).click() | ||
await page.getByRole('button', { name: 'Edit' }).nth(1).click() | ||
await page.getByRole('button').nth(1).click() | ||
await page.getByRole('button', { name: 'Generate File' }).click() | ||
}) | ||
}) |
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 |
---|---|---|
|
@@ -93,36 +93,3 @@ test('test es-419 resource types', async ({ page }) => { | |
await page.getByRole('button', { name: 'Generate File' }).click() | ||
}) | ||
|
||
test('test stet', async ({ page }) => { | ||
await page.goto('http://localhost:8001/stet') | ||
await page.getByLabel('English en').check() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByText('Cebuano').click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByRole('button', { name: 'Generate File' }).click() | ||
}) | ||
|
||
test('test stet 2', async ({ page }) => { | ||
await page.goto('http://localhost:8001/stet') | ||
await page.getByText('English').click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByRole('button', { name: 'Back' }).click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByText('Bichelamar (Bislama)').click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByRole('link', { name: 'Target Language' }).click() | ||
await page.getByRole('link', { name: 'Source Language' }).click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByRole('button', { name: 'Back' }).click() | ||
await page.getByRole('button', { name: 'Back' }).click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByRole('button', { name: 'Edit' }).click() | ||
await page.getByRole('button', { name: 'Edit' }).click() | ||
await page.getByRole('button', { name: 'Next' }).click() | ||
await page.getByLabel('Email me a copy of my').check() | ||
await page.getByPlaceholder('Type email address here (').click() | ||
await page.getByPlaceholder('Type email address here (').fill('[email protected]') | ||
await page.getByRole('button', { name: 'Submit' }).click() | ||
await page.getByRole('button', { name: 'Generate File' }).click() | ||
}) |