Bug 182212 - Some test cases in accessibility/mac/selection-notification-focus-change.html fail
Summary: Some test cases in accessibility/mac/selection-notification-focus-change.html...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Accessibility (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Ryosuke Niwa
URL:
Keywords: InRadar
Depends on: 182198
Blocks:
  Show dependency treegraph
 
Reported: 2018-01-26 23:11 PST by Ryosuke Niwa
Modified: 2018-02-07 17:08 PST (History)
9 users (show)

See Also:


Attachments
Fixes the test (13.08 KB, patch)
2018-01-26 23:27 PST, Ryosuke Niwa
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews123 for ios-simulator-wk2 (2.23 MB, application/zip)
2018-01-27 00:58 PST, EWS Watchlist
no flags Details
Archive of layout-test-results from ews114 for mac-sierra (3.56 MB, application/zip)
2018-01-27 03:00 PST, EWS Watchlist
no flags Details
Fixed macOS WK1 tests (14.52 KB, patch)
2018-01-29 11:04 PST, Ryosuke Niwa
no flags Details | Formatted Diff | Diff
Archive of layout-test-results from ews124 for ios-simulator-wk2 (5.46 MB, application/zip)
2018-01-29 12:37 PST, EWS Watchlist
no flags Details
Fixed more tests (23.27 KB, patch)
2018-01-31 23:49 PST, Ryosuke Niwa
no flags Details | Formatted Diff | Diff
Fixed more tests (20.13 KB, patch)
2018-01-31 23:51 PST, Ryosuke Niwa
no flags Details | Formatted Diff | Diff
Fixed per Antti's comments (20.63 KB, patch)
2018-02-01 01:40 PST, Ryosuke Niwa
koivisto: review+
Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Ryosuke Niwa 2018-01-26 23:11:39 PST
Fix the test refactored in https://trac.webkit.org/changeset/227713.
Comment 1 Radar WebKit Bug Importer 2018-01-26 23:11:52 PST
<rdar://problem/36937147>
Comment 2 Ryosuke Niwa 2018-01-26 23:27:39 PST
Created attachment 332462 [details]
Fixes the test
Comment 3 Wenson Hsieh 2018-01-26 23:48:54 PST
Comment on attachment 332462 [details]
Fixes the test

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

> Source/WebCore/ChangeLog:13
> +        (WebCore::Element::focus): Removed an unnecessarily synchronous layout update.

Nit - an unnecessary synchronous layout update.
Comment 4 Ryosuke Niwa 2018-01-27 00:14:13 PST
Comment on attachment 332462 [details]
Fixes the test

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

>> Source/WebCore/ChangeLog:13
>> +        (WebCore::Element::focus): Removed an unnecessarily synchronous layout update.
> 
> Nit - an unnecessary synchronous layout update.

This is unnecessary after https://trac.webkit.org/changeset/227664 and https://trac.webkit.org/changeset/226823.
Comment 5 Ryosuke Niwa 2018-01-27 00:14:30 PST
<rdar://problem/36930430>
Comment 6 EWS Watchlist 2018-01-27 00:58:26 PST
Comment on attachment 332462 [details]
Fixes the test

Attachment 332462 [details] did not pass ios-sim-ews (ios-simulator-wk2):
Output: http://webkit-queues.webkit.org/results/6230620

New failing tests:
editing/input/caret-at-the-edge-of-input.html
accessibility/ios-simulator/table-cell-for-row-col.html
fast/forms/input-text-scroll-left-on-blur.html
accessibility/ios-simulator/header-elements.html
Comment 7 EWS Watchlist 2018-01-27 00:58:27 PST
Created attachment 332464 [details]
Archive of layout-test-results from ews123 for ios-simulator-wk2

The attached test failures were seen while running run-webkit-tests on the ios-sim-ews.
Bot: ews123  Port: ios-simulator-wk2  Platform: Mac OS X 10.12.6
Comment 8 EWS Watchlist 2018-01-27 03:00:19 PST
Comment on attachment 332462 [details]
Fixes the test

Attachment 332462 [details] did not pass mac-debug-ews (mac):
Output: http://webkit-queues.webkit.org/results/6231284

Number of test failures exceeded the failure limit.
Comment 9 EWS Watchlist 2018-01-27 03:00:20 PST
Created attachment 332467 [details]
Archive of layout-test-results from ews114 for mac-sierra

The attached test failures were seen while running run-webkit-tests on the mac-debug-ews.
Bot: ews114  Port: mac-sierra  Platform: Mac OS X 10.12.6
Comment 10 Ryosuke Niwa 2018-01-29 11:04:06 PST
Created attachment 332560 [details]
Fixed macOS WK1 tests
Comment 11 EWS Watchlist 2018-01-29 12:37:23 PST
Comment on attachment 332560 [details]
Fixed macOS WK1 tests

Attachment 332560 [details] did not pass ios-sim-ews (ios-simulator-wk2):
Output: http://webkit-queues.webkit.org/results/6251492

New failing tests:
editing/input/caret-at-the-edge-of-input.html
accessibility/ios-simulator/table-cell-for-row-col.html
fast/forms/input-text-scroll-left-on-blur.html
accessibility/ios-simulator/header-elements.html
Comment 12 EWS Watchlist 2018-01-29 12:37:25 PST
Created attachment 332569 [details]
Archive of layout-test-results from ews124 for ios-simulator-wk2

The attached test failures were seen while running run-webkit-tests on the ios-sim-ews.
Bot: ews124  Port: ios-simulator-wk2  Platform: Mac OS X 10.12.6
Comment 13 Ryosuke Niwa 2018-01-31 23:49:16 PST
Created attachment 332853 [details]
Fixed more tests
Comment 14 Ryosuke Niwa 2018-01-31 23:51:36 PST
Created attachment 332854 [details]
Fixed more tests
Comment 15 Antti Koivisto 2018-02-01 01:25:52 PST
Comment on attachment 332854 [details]
Fixed more tests

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

> Source/WebCore/editing/FrameSelection.cpp:378
> +    m_selectionRevealIntent = intent;
>      m_pendingSelectionUpdate = true;

m_selectionRevealIntent is never reset. m_pendingSelectionUpdate bit can get also set by FrameSelection::setNeedsSelectionUpdate in which case we presumably use whatever intent was set earlier. This doesn't seem right.
Comment 16 Ryosuke Niwa 2018-02-01 01:27:52 PST
(In reply to Antti Koivisto from comment #15)
> Comment on attachment 332854 [details]
> Fixed more tests
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=332854&action=review
> 
> > Source/WebCore/editing/FrameSelection.cpp:378
> > +    m_selectionRevealIntent = intent;
> >      m_pendingSelectionUpdate = true;
> 
> m_selectionRevealIntent is never reset. m_pendingSelectionUpdate bit can get
> also set by FrameSelection::setNeedsSelectionUpdate in which case we
> presumably use whatever intent was set earlier. This doesn't seem right.

That's okay. What's not okay is that we're not resetting m_selectionRevealMode in some cases. We should probably fix that in a separate patch since that's a pre-existing bug.
Comment 17 Ryosuke Niwa 2018-02-01 01:29:59 PST
Let's track that in the bug 182378.
Comment 18 Ryosuke Niwa 2018-02-01 01:40:14 PST
Created attachment 332861 [details]
Fixed per Antti's comments
Comment 19 Ryosuke Niwa 2018-02-01 15:07:39 PST
Comment on attachment 332861 [details]
Fixed per Antti's comments

Landing this manually instead.
Comment 20 Ryosuke Niwa 2018-02-01 15:11:15 PST
Committed r227983: <https://trac.webkit.org/changeset/227983>
Comment 21 Ryan Haddad 2018-02-07 16:57:14 PST
(In reply to Ryosuke Niwa from comment #20)
> Committed r227983: <https://trac.webkit.org/changeset/227983>
This change has caused LayoutTest fast/dom/adopt-node-crash-2.html to become a flaky failure on High Sierra Release WK2 and Sierra Release WK2:
https://build.webkit.org/results/Apple%20Sierra%20Release%20WK2%20(Tests)/r228225%20(7494)/results.html

I am able to reproduce the failure with a build of r227984 with the following:
run-webkit-tests fast/dom/adopt-node-crash-2.html -fg --iter 100 --exit-after-n-failures 1

I cannot reproduce with a build of r227982.
Comment 22 Ryosuke Niwa 2018-02-07 17:08:52 PST
(In reply to Ryan Haddad from comment #21)
> (In reply to Ryosuke Niwa from comment #20)
> > Committed r227983: <https://trac.webkit.org/changeset/227983>
> This change has caused LayoutTest fast/dom/adopt-node-crash-2.html to become
> a flaky failure on High Sierra Release WK2 and Sierra Release WK2:
> https://build.webkit.org/results/Apple%20Sierra%20Release%20WK2%20(Tests)/
> r228225%20(7494)/results.html
> 
> I am able to reproduce the failure with a build of r227984 with the
> following:
> run-webkit-tests fast/dom/adopt-node-crash-2.html -fg --iter 100
> --exit-after-n-failures 1
> 
> I cannot reproduce with a build of r227982.

I think this is a bug in the test. Tracking that in https://bugs.webkit.org/show_bug.cgi?id=182589.