-
Notifications
You must be signed in to change notification settings - Fork 3
chore: update-flakey-tests #450
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
ryanbas21
wants to merge
3
commits into
main
Choose a base branch
from
flakey-tests
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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 hidden or 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 hidden or 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 |
|---|---|---|
|
|
@@ -8,3 +8,7 @@ | |
| */ | ||
|
|
||
| import './styles.css'; | ||
|
|
||
| // window.addEventListener('load', () => { | ||
| // console.log('loaded parent'); | ||
| // }); | ||
This file contains hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 hidden or 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 |
|---|---|---|
|
|
@@ -17,9 +17,11 @@ import { asyncEvents } from './utils/async-events.js'; | |
|
|
||
| test.describe('PingAM login and get token tests', () => { | ||
| test('background login with valid credentials', async ({ page }) => { | ||
| const { navigate, clickButton } = asyncEvents(page); | ||
| await navigate('/ping-am/'); | ||
| const { /* navigate, */ clickButton } = asyncEvents(page); | ||
| // await page.goto('/ping-am/'); | ||
| await page.goto('/ping-am/'); | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Can you explain this change? |
||
| expect(page.url()).toBe('http://localhost:8443/ping-am/'); | ||
| await expect(page.locator('#loading')).toBeHidden(); | ||
|
|
||
| await clickButton('Login (Background)', '/authorize'); | ||
|
|
||
|
|
@@ -33,9 +35,10 @@ test.describe('PingAM login and get token tests', () => { | |
| }); | ||
|
|
||
| test('redirect login with valid credentials', async ({ page }) => { | ||
| const { navigate, clickButton } = asyncEvents(page); | ||
| await navigate('/ping-am/'); | ||
| const { clickButton } = asyncEvents(page); | ||
| await page.goto('/ping-am/'); | ||
| expect(page.url()).toBe('http://localhost:8443/ping-am/'); | ||
| await expect(page.locator('#loading')).toBeHidden(); | ||
|
|
||
| await clickButton('Login (Redirect)', '/authorize'); | ||
|
|
||
|
|
@@ -49,9 +52,10 @@ test.describe('PingAM login and get token tests', () => { | |
| }); | ||
|
|
||
| test('background login with invalid client id fails', async ({ page }) => { | ||
| const { navigate } = asyncEvents(page); | ||
| await navigate('/ping-am/?clientid=bad-id'); | ||
| // const { navigate } = asyncEvents(page); | ||
| await page.goto('/ping-am/?clientid=bad-id'); | ||
| expect(page.url()).toBe('http://localhost:8443/ping-am/?clientid=bad-id'); | ||
| await expect(page.locator('#loading')).toBeHidden(); | ||
|
|
||
| await page.getByRole('button', { name: 'Login (Background)' }).click(); | ||
|
|
||
|
|
@@ -65,9 +69,10 @@ test.describe('PingAM login and get token tests', () => { | |
|
|
||
| test.describe('PingOne login and get token tests', () => { | ||
| test('background login with valid credentials', async ({ page }) => { | ||
| const { navigate, clickButton } = asyncEvents(page); | ||
| await navigate('/ping-one/'); | ||
| const { clickButton } = asyncEvents(page); | ||
| await page.goto('/ping-one/'); | ||
| expect(page.url()).toBe('http://localhost:8443/ping-one/'); | ||
| await expect(page.locator('#loading')).toBeHidden(); | ||
|
|
||
| await clickButton('Login (Background)', '/authorize'); | ||
|
|
||
|
|
@@ -82,9 +87,10 @@ test.describe('PingOne login and get token tests', () => { | |
| }); | ||
|
|
||
| test('redirect login with valid credentials', async ({ page }) => { | ||
| const { navigate, clickButton } = asyncEvents(page); | ||
| await navigate('/ping-one/'); | ||
| const { clickButton } = asyncEvents(page); | ||
| await page.goto('/ping-one/'); | ||
| expect(page.url()).toBe('http://localhost:8443/ping-one/'); | ||
| await expect(page.locator('#loading')).toBeHidden(); | ||
|
|
||
| await clickButton('Login (Redirect)', '/authorize'); | ||
|
|
||
|
|
@@ -99,9 +105,10 @@ test.describe('PingOne login and get token tests', () => { | |
| }); | ||
|
|
||
| test('login with invalid client id fails', async ({ page }) => { | ||
| const { navigate } = asyncEvents(page); | ||
| await navigate('/ping-one/?clientid=bad-id'); | ||
| // const { navigate } = asyncEvents(page); | ||
| await page.goto('/ping-one/?clientid=bad-id'); | ||
| expect(page.url()).toBe('http://localhost:8443/ping-one/?clientid=bad-id'); | ||
| await expect(page.locator('#loading')).toBeHidden(); | ||
|
|
||
| await page.getByRole('button', { name: 'Login (Background)' }).click(); | ||
|
|
||
|
|
@@ -113,11 +120,12 @@ test.describe('PingOne login and get token tests', () => { | |
| }); | ||
|
|
||
| test('login with pi.flow response mode', async ({ page }) => { | ||
| const { navigate, clickButton } = asyncEvents(page); | ||
| await navigate('/ping-one/?piflow=true'); | ||
| const { clickButton } = asyncEvents(page); | ||
| await page.goto('/ping-one/?piflow=true'); | ||
| expect(page.url()).toBe('http://localhost:8443/ping-one/?piflow=true'); | ||
| await expect(page.locator('#loading')).toBeHidden(); | ||
|
|
||
| await page.on('request', (request) => { | ||
| page.on('request', (request) => { | ||
| const method = request.method(); | ||
| const requestUrl = request.url(); | ||
|
|
||
|
|
@@ -140,9 +148,10 @@ test.describe('PingOne login and get token tests', () => { | |
| }); | ||
|
|
||
| test('login with invalid state fails with error', async ({ page }) => { | ||
| const { navigate } = asyncEvents(page); | ||
| await navigate('/ping-am/?code=12345&state=abcxyz'); | ||
| // const { navigate } = asyncEvents(page); | ||
| await page.goto('/ping-am/?code=12345&state=abcxyz'); | ||
| expect(page.url()).toBe('http://localhost:8443/ping-am/?code=12345&state=abcxyz'); | ||
| await expect(page.locator('#loading')).toBeHidden(); | ||
|
|
||
| await expect(page.locator('.error')).toContainText(`"error": "State mismatch"`); | ||
| await expect(page.locator('.error')).toContainText(`"type": "state_error"`); | ||
|
|
@@ -152,9 +161,10 @@ test('login with invalid state fails with error', async ({ page }) => { | |
| }); | ||
|
|
||
| test('oidc client fails to initialize with bad wellknown', async ({ page }) => { | ||
| const { navigate } = asyncEvents(page); | ||
| await navigate('/ping-am/?wellknown=bad-wellknown'); | ||
| // const { navigate } = asyncEvents(page); | ||
| await page.goto('/ping-am/?wellknown=bad-wellknown'); | ||
| expect(page.url()).toBe('http://localhost:8443/ping-am/?wellknown=bad-wellknown'); | ||
| await expect(page.locator('#loading')).toBeHidden(); | ||
|
|
||
| await page.getByRole('button', { name: 'Login (Background)' }).click(); | ||
|
|
||
|
|
||
This file contains hidden or 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
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
What is the functional reason for this
toPass?