-
-
Notifications
You must be signed in to change notification settings - Fork 1.7k
chore(e2e): Reduce solid e2e tests flakines by waiting for more speci… #12455
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
Conversation
@@ -3,7 +3,7 @@ import { waitForError } from '@sentry-internal/test-utils'; | |||
|
|||
test('captures an exception', async ({ page }) => { | |||
const errorEventPromise = waitForError('solid', errorEvent => { | |||
return !errorEvent.type; | |||
return !errorEvent.type && errorEvent.transaction === '/error-boundary-example'; |
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.
Ideally you find a very specific way to wait for events, as they may leak between tests.
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.
Any ideas? I can only think of creating a different route per test.
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.
different route per test
I think this is what we usually do 😬 another option would be to configure playwright to only sequentially run tests but it's also not ideal...
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.
The leaking I had happened between the errorboundary tests and the normal error tests, and there the transaction
field is different. Maybe we can leave it as is for now and see if there's more flakiness to fix 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.
You can also set tags or contexts in the tests and assert on them!
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.
Sure we can always go step by step. Let's just keep in mind that this could be a further source of flakiness if we observe any more of them.
No description provided.