[Webkit-unassigned] [Bug 198450] New: TestWebKitAPI.WKWebView.LocalStorageProcessSuspends is flaky

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Fri May 31 20:59:43 PDT 2019


https://bugs.webkit.org/show_bug.cgi?id=198450

            Bug ID: 198450
           Summary: TestWebKitAPI.WKWebView.LocalStorageProcessSuspends is
                    flaky
           Product: WebKit
           Version: WebKit Nightly Build
          Hardware: Unspecified
                OS: Unspecified
            Status: NEW
          Severity: Normal
          Priority: P2
         Component: New Bugs
          Assignee: webkit-unassigned at lists.webkit.org
          Reporter: sihui_liu at apple.com

We used two WKWebViews in this test, one for setting local storage item and the other for checking that local storage item is correctly set.
The test goes like this:
1. Set item value to be "value" in webView1
2. Suspend network process
3. Set item value to be "newValue" in webView1
4. Get item value from webView2. The value should be "value" because network process cannot notify webView2 about new value during its suspension.
5. Wake up network process
6. Get item value from webView. The value should be "newValue" as network process handles the update and makes notification.

In step 6, we relies on web page of webView2 to send back a message that has the item value. To implement this, we let that web page periodically check the item value and send back a message when it detects the value has changed or *the limit of checks has been reached*.

Because web process is not suspended, it is possible that that web page in webView2 finishes the check and sends a message earlier than step 6. Therefore, we may not get the expected message during the wait in step 6 and the test times out. Also, the message content may be incorrect if the check finishes before network process resumes.

To make the test more robust, we can use storage event instead of the periodic check.

-- 
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20190601/3cacff42/attachment-0001.html>


More information about the webkit-unassigned mailing list