Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: 3857b6ae9b5240a9d2124501ac70c74b7d549cdf
      
https://github.com/WebKit/WebKit/commit/3857b6ae9b5240a9d2124501ac70c74b7d549cdf
  Author: Alex Christensen <[email protected]>
  Date:   2024-10-29 (Tue, 29 Oct 2024)

  Changed paths:
    M Tools/TestWebKitAPI/Tests/WebKitCocoa/AppPrivacyReport.mm
    M Tools/TestWebKitAPI/Tests/WebKitCocoa/ContentSecurityPolicy.mm
    M Tools/TestWebKitAPI/Tests/WebKitCocoa/WebPushDaemon.mm
    M Tools/TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm
    M Tools/TestWebKitAPI/cocoa/TestWKWebView.h
    M Tools/TestWebKitAPI/cocoa/TestWKWebView.mm

  Log Message:
  -----------
  Re-enable TestWebKitAPI.WebpagePreferences.WebsitePoliciesAutoplayQuirks on 
new macOS
https://bugs.webkit.org/show_bug.cgi?id=282214
rdar://137267112

Reviewed by Wenson Hsieh.

Sometimes the TestWebKitAPI::Util::run call in TestWKWebView.waitForMessage 
causes
the runloop to spin until multiple messages have been received.  This makes it 
so
if you have multiple calls to waitForMessage without anything being done 
between them,
it can sometimes be waiting for a message it has already received, causing the 
test
to time out.  To fix this, use a Deque to be more robust against receiving 
multiple
messages in one call to Util::run.

A quick audit of the uses of TestWKWebView.waitForMessage found several more 
places
this is an issue, some of which had resulted in disabled tests.  I fixed this 
everywhere.

* Tools/TestWebKitAPI/Tests/WebKitCocoa/WebPushDaemon.mm:
* Tools/TestWebKitAPI/Tests/WebKitCocoa/WebsitePolicies.mm:
(TEST(WebpagePreferences, WebsitePoliciesAutoplayQuirks)):
* Tools/TestWebKitAPI/cocoa/TestWKWebView.h:
* Tools/TestWebKitAPI/cocoa/TestWKWebView.mm:
(-[TestMessageHandler addMessage:withHandler:]):
(-[TestMessageHandler userContentController:didReceiveScriptMessage:]):
(-[TestWKWebView performAfterReceivingAnyMessage:]):
(-[TestMessageHandler setWildcardMessageHandler:]): Deleted.

Canonical link: https://commits.webkit.org/285843@main



To unsubscribe from these emails, change your notification settings at 
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes

Reply via email to