Bug 101208 - fast/events/popup-allowed-from-gesture-initiated-event.html is flaky
Summary: fast/events/popup-allowed-from-gesture-initiated-event.html is flaky
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: 528+ (Nightly build)
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Chris Dumez
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-11-05 04:47 PST by Chris Dumez
Modified: 2012-11-05 06:08 PST (History)
6 users (show)

See Also:


Attachments
Patch (3.84 KB, patch)
2012-11-05 04:52 PST, Chris Dumez
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Chris Dumez 2012-11-05 04:47:09 PST
fast/events/popup-allowed-from-gesture-initiated-event.html is flaky.

We sometimes get the following diff on EFL port:
--- /home/buildslave-1/webkit-buildslave/efl-linux-64-debug-wk2/build/layout-test-results/fast/events/popup-allowed-from-gesture-initiated-event-expected.txt
+++ /home/buildslave-1/webkit-buildslave/efl-linux-64-debug-wk2/build/layout-test-results/fast/events/popup-allowed-from-gesture-initiated-event-actual.txt
@@ -1,4 +1,3 @@
 Click Here  Click Here Too
 PASS win is non-null.
-PASS win is non-null.
Comment 1 Chris Dumez 2012-11-05 04:52:21 PST
Created attachment 172315 [details]
Patch
Comment 2 Kenneth Rohde Christiansen 2012-11-05 05:09:17 PST
Comment on attachment 172315 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=172315&action=review

> LayoutTests/fast/events/popup-allowed-from-gesture-initiated-event.html:34
> +                setTimeout(doneHandler, 1);

why not just 0?

> LayoutTests/fast/events/popup-allowed-from-gesture-initiated-event.html:41
> +                    setTimeout(doneHandler, 1);

So it can take a while to close? hmm, so we are just making it less flaky?
Comment 3 Chris Dumez 2012-11-05 05:47:57 PST
Comment on attachment 172315 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=172315&action=review

>> LayoutTests/fast/events/popup-allowed-from-gesture-initiated-event.html:34
>> +                setTimeout(doneHandler, 1);
> 
> why not just 0?

I honestly copied this from another test (fast/dom/Window/new-window-opener.html). 0 would certainly work but since the window takes a while to close apparently, I would actually do the opposite and put a bigger value here (like 250 milliseconds) to avoid invoking doneHandler() too many times.

>> LayoutTests/fast/events/popup-allowed-from-gesture-initiated-event.html:41
>> +                    setTimeout(doneHandler, 1);
> 
> So it can take a while to close? hmm, so we are just making it less flaky?

It completely resolves flakiness for me. I don't see why this would make it only "less" flaky. We are properly waiting for the window to close so no flakiness is possible here.
Comment 4 Kenneth Rohde Christiansen 2012-11-05 05:51:33 PST
Comment on attachment 172315 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=172315&action=review

>>> LayoutTests/fast/events/popup-allowed-from-gesture-initiated-event.html:41
>>> +                    setTimeout(doneHandler, 1);
>> 
>> So it can take a while to close? hmm, so we are just making it less flaky?
> 
> It completely resolves flakiness for me. I don't see why this would make it only "less" flaky. We are properly waiting for the window to close so no flakiness is possible here.

Sure, I See that now. It keeps calling until it is closed. So what if it never closes? Should you have a recursion count?
Comment 5 Chris Dumez 2012-11-05 05:57:43 PST
(In reply to comment #4)
> (From update of attachment 172315 [details])
> View in context: https://bugs.webkit.org/attachment.cgi?id=172315&action=review
> 
> >>> LayoutTests/fast/events/popup-allowed-from-gesture-initiated-event.html:41
> >>> +                    setTimeout(doneHandler, 1);
> >> 
> >> So it can take a while to close? hmm, so we are just making it less flaky?
> > 
> > It completely resolves flakiness for me. I don't see why this would make it only "less" flaky. We are properly waiting for the window to close so no flakiness is possible here.
> 
> Sure, I See that now. It keeps calling until it is closed. So what if it never closes? Should you have a recursion count?

Other tests I've seen that wait for a window to close() don't seem to do anything specific regarding recursion. Actually, what will happen is that the test will time out (and therefore fail).
Comment 6 WebKit Review Bot 2012-11-05 06:08:27 PST
Comment on attachment 172315 [details]
Patch

Clearing flags on attachment: 172315

Committed r133461: <http://trac.webkit.org/changeset/133461>
Comment 7 WebKit Review Bot 2012-11-05 06:08:31 PST
All reviewed patches have been landed.  Closing bug.