Skip to content
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

front: fix flaky test 012 and 006 #9877

Merged
merged 1 commit into from
Nov 28, 2024
Merged

front: fix flaky test 012 and 006 #9877

merged 1 commit into from
Nov 28, 2024

Conversation

Maymanaf
Copy link
Contributor

@Maymanaf Maymanaf commented Nov 27, 2024

This PR addresses the flakiness in tests 006 and 012.
The Playwright runner is very fast, which sometimes prevents the results from being updated in time. To resolve this, I added timeouts

@github-actions github-actions bot added the area:front Work on Standard OSRD Interface modules label Nov 27, 2024
@Maymanaf Maymanaf force-pushed the aba/e2e-fix-flaky-tests branch 4 times, most recently from d85cf49 to 9cac7c4 Compare November 27, 2024 18:39
@Maymanaf Maymanaf force-pushed the aba/e2e-fix-flaky-tests branch from 9cac7c4 to 541a9f2 Compare November 28, 2024 08:35
@Maymanaf Maymanaf marked this pull request as ready for review November 28, 2024 08:35
@Maymanaf Maymanaf requested a review from a team as a code owner November 28, 2024 08:35
@Maymanaf Maymanaf requested review from Synar, clarani and Yohh November 28, 2024 08:36
Copy link
Contributor

@Synar Synar left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Nice PR! There's a slight redundancy with 8248abe which adds await page.waitForSelector(containerSelector, { state: 'visible' }); to the top of the scroll container function

Copy link
Contributor

@clarani clarani left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM ✅

@Maymanaf
Copy link
Contributor Author

Nice PR! There's a slight redundancy with 8248abe which adds await page.waitForSelector(containerSelector, { state: 'visible' }); to the top of the scroll container function

I don't see any redundancy in this case, as I didn't modify the scroll function. Additionally, the use of waitForSelector shouldn't cause any issues since it doesn't rely on a fixed timeout.

Copy link
Contributor

@Yohh Yohh left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@Maymanaf Maymanaf added this pull request to the merge queue Nov 28, 2024
Merged via the queue into dev with commit 003ece7 Nov 28, 2024
27 checks passed
@Maymanaf Maymanaf deleted the aba/e2e-fix-flaky-tests branch November 28, 2024 10:45
@Synar
Copy link
Contributor

Synar commented Nov 28, 2024

Nice PR! There's a slight redundancy with 8248abe which adds await page.waitForSelector(containerSelector, { state: 'visible' }); to the top of the scroll container function

I don't see any redundancy in this case, as I didn't modify the scroll function. Additionally, the use of waitForSelector shouldn't cause any issues since it doesn't rely on a fixed timeout.

Yes, but you are waiting for the table to be visible before calling the scroll function at multiple points, and my change makes the scroll function wait for the component it should scroll to be visible, so we solved the same bug twice. It shouldn't pose any issue though. If the table is visible once, it should be visible twice =p

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:front Work on Standard OSRD Interface modules
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants