Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 0d63b2349ead3da87407625988c87e30abd94945
https://github.com/WebKit/WebKit/commit/0d63b2349ead3da87407625988c87e30abd94945
Author: Zak Ridouh <[email protected]>
Date: 2026-06-13 (Sat, 13 Jun 2026)
Changed paths:
M LayoutTests/platform/ios-site-isolation/TestExpectations
M LayoutTests/platform/mac-site-isolation/TestExpectations
M Tools/WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp
M Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp
M Tools/WebKitTestRunner/InjectedBundle/TestRunner.h
M Tools/WebKitTestRunner/TestInvocation.cpp
M Tools/WebKitTestRunner/TestInvocation.h
Log Message:
-----------
[Site Isolation] Fix WebKitTestRunner not draining the work queue after
notifyDone()
https://bugs.webkit.org/show_bug.cgi?id=316925
rdar://179387068
Reviewed by Alex Christensen.
Under site isolation, notifyDone() resolves asynchronously: it sets
m_notifyDoneMessageSent and posts the dump as a NotifyDone page message.
GetWaitUntilDone() then stays true via m_notifyDoneMessageSent, which is meant
only to defer the dump — but it also stopped frameDidChangeLocation() from
draining the work queue. So a notifyDone() called mid-work-queue (e.g. from a
page reached via a redirect) ended the test before queued loads/navigations
ran, producing truncated output. Non-site-isolation is unaffected: there
notifyDone() is synchronous and never sets m_notifyDoneMessageSent.
Gate the work queue on a new isWaitingUntilDone() (m_waitUntilDone alone) so it
keeps draining after notifyDone(), while the dump stays deferred via
shouldWaitUntilDone(). Hold the deferred NotifyDone message until the queue
drains, then deliver it.
Remove the back/forward navigation tests this fixes from the mac and iOS
site-isolation TestExpectations.
* LayoutTests/platform/ios-site-isolation/TestExpectations:
* LayoutTests/platform/mac-site-isolation/TestExpectations:
* Tools/WebKitTestRunner/InjectedBundle/InjectedBundlePage.cpp:
(WTR::InjectedBundlePage::frameDidChangeLocation):
* Tools/WebKitTestRunner/InjectedBundle/TestRunner.cpp:
(WTR::TestRunner::isWaitingUntilDone const):
* Tools/WebKitTestRunner/InjectedBundle/TestRunner.h:
* Tools/WebKitTestRunner/TestInvocation.cpp:
(WTR::TestInvocation::didReceiveMessageFromInjectedBundle):
(WTR::TestInvocation::didReceiveSynchronousMessageFromInjectedBundle):
(WTR::TestInvocation::resolveNotifyDone):
* Tools/WebKitTestRunner/TestInvocation.h:
Canonical link: https://commits.webkit.org/315185@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications