mirror of
https://github.com/RGBCube/serenity
synced 2025-05-14 09:24:57 +00:00
headless-browser: Don't choke on subframe load completions
This didn't break any existing tests, but I have to do this for an upcoming test to not bring everything down.
This commit is contained in:
parent
9759f44faf
commit
8586897928
1 changed files with 3 additions and 1 deletions
|
@ -303,7 +303,9 @@ static ErrorOr<TestResult> run_dump_test(HeadlessWebContentView& view, StringVie
|
|||
} else if (mode == TestMode::Text) {
|
||||
|
||||
view.on_load_finish = [&](auto const& loaded_url) {
|
||||
VERIFY(url.equals(loaded_url, URL::ExcludeFragment::Yes));
|
||||
// NOTE: We don't want subframe loads to trigger the test finish.
|
||||
if (!url.equals(loaded_url, URL::ExcludeFragment::Yes))
|
||||
return;
|
||||
did_finish_loading = true;
|
||||
if (did_finish_test)
|
||||
loop.quit(0);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue