[Webkit-unassigned] [Bug 154333] Add test to check scroll animator events after a history navigation

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Sat Feb 20 00:47:49 PST 2016


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

--- Comment #9 from Carlos Garcia Campos <cgarcia at igalia.com> ---
(In reply to comment #8)
> Comment on attachment 271541 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=271541&action=review
> 
> Looks good, except for the WK1 test failure that needs fixed.

We just need to skip this test in wk1, I don't see that a reason to reject the patch.

> > LayoutTests/fast/scrolling/scroll-animator-events-after-history-navigation.html:31
> > +          delete sessionStorage.didNavigate;
> 
> Why do you need to do this? The test is about to end!

To clean up the session storage so that it won't affect other tests that could use also didNavigate. It's quite common to do this in layout tests.

> > LayoutTests/fast/scrolling/scroll-animator-events-after-history-navigation.html:37
> > +          sessionStorage.didNavigate = true;
> 
> This is needed... why, so that the page enters the page cache?

No, this has nothing to do with the page cache. Please, if you have questions about the patch or you didn't understand a part of it, ask any questions before deciding to reject the patch. When a test does a navigation or reload and you want to do different things depending on every navigation you need to store some state somewhere that is alive during navigation, and we normally use the session storage for that. In this case, when the test is loaded the first time we want to navigate to another page that will navigate back. When the page is loaded the second time, we just want to finish the test. The way the test know if it's the first navigation or not is checking the sessionStorage.didNavigate value.

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


More information about the webkit-unassigned mailing list