Skip to content

Commit

Permalink
Wait for Load instead of NetworkIdle
Browse files Browse the repository at this point in the history
We don't have to wait until NetworkIdle/Hydrated, because the app blocks user interaction automatically.
  • Loading branch information
myieye committed Oct 27, 2023
1 parent e64e8e8 commit b6aa726
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions backend/Testing/Browser/Page/BasePage.cs
Original file line number Diff line number Diff line change
Expand Up @@ -36,11 +36,11 @@ public async Task<T> WaitFor()
{
if (Url is not null)
{
await Page.WaitForURLAsync(Url, new() { WaitUntil = WaitUntilState.NetworkIdle });
await Page.WaitForURLAsync(Url, new() { WaitUntil = WaitUntilState.Load });
}
else
{
await Page.WaitForLoadStateAsync(LoadState.NetworkIdle);
await Page.WaitForLoadStateAsync(LoadState.Load);
}
await Task.WhenAll(TestLocators.Select(l => l.WaitForAsync()));
return (T)this;
Expand Down

0 comments on commit b6aa726

Please sign in to comment.