New issue
Advanced search Search tips
Note: Color blocks (like or ) mean that a user may not be available. Tooltip shows the reason.

Issue 803086 link

Starred by 1 user

Issue metadata

Status: Available
Owner: ----
Cc:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 3
Type: Bug

Blocking:
issue 871416



Sign in to add a comment

Replace spatial-navigation-utils.js with snav-testharness.js

Reported by hu...@vewd.com, Jan 17 2018

Issue description

Most of spatnav's layout tests use a helper called spatial-navigation-utils.js that depends on the deprecated *expected.txt-files-way of testing.

To avoid rewriting the tests' logic, hopefully we only need to make spatial-navigation-utils.js use testharness' asserts. 
 

Comment 1 by junho092...@lge.com, Jan 18 2018

This is very good work!

Comment 2 by hu...@vewd.com, Mar 22 2018

Owner: hu...@vewd.com
Status: Started (was: Available)
Blocking: 871416
Project Member

Comment 4 by bugdroid1@chromium.org, Aug 8

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/31ad1a83e8e9ea55d23e51abf439e334822d9ef5

commit 31ad1a83e8e9ea55d23e51abf439e334822d9ef5
Author: Hugo Holgersson <hugoh@vewd.com>
Date: Wed Aug 08 15:35:33 2018

Convert the first old snav*-layout tests to testharness.js

This introduces assertFocusMoves() that helps us to write
testharness.js-tests with the compact and declarative "step focus and
check result"-syntax of the older snav*-tests.

I've converted snav-div-scrollable-but-without-focusable-content.html
and snav-radio.html so these do no longer need -expected.txt-files,
asserts are now made through testharness.js instead.
Other snav*-tests could be converted by following their example.

Bug: 803086
Change-Id: I5310f16492b233f894eda7e3e6b9691926670b06
Reviewed-on: https://chromium-review.googlesource.com/998193
Reviewed-by: Philip Jägenstedt <foolip@chromium.org>
Commit-Queue: Hugo Holgersson <hugoh@vewd.com>
Cr-Commit-Position: refs/heads/master@{#581570}
[add] https://crrev.com/31ad1a83e8e9ea55d23e51abf439e334822d9ef5/third_party/WebKit/LayoutTests/fast/spatial-navigation/resources/snav-testharness.js
[modify] https://crrev.com/31ad1a83e8e9ea55d23e51abf439e334822d9ef5/third_party/WebKit/LayoutTests/fast/spatial-navigation/resources/spatial-navigation-utils.js
[delete] https://crrev.com/a2a9bf5a635a1ed7028fef962adc27793e04c20d/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-div-scrollable-but-without-focusable-content-expected.txt
[modify] https://crrev.com/31ad1a83e8e9ea55d23e51abf439e334822d9ef5/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-div-scrollable-but-without-focusable-content.html
[delete] https://crrev.com/a2a9bf5a635a1ed7028fef962adc27793e04c20d/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-radio-expected.txt
[modify] https://crrev.com/31ad1a83e8e9ea55d23e51abf439e334822d9ef5/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-radio.html

Project Member

Comment 5 by bugdroid1@chromium.org, Aug 21

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/fc8f959d596a079a55449b3ea84e7c63736a2a56

commit fc8f959d596a079a55449b3ea84e7c63736a2a56
Author: JunHo Seo <junho0924.seo@lge.com>
Date: Tue Aug 21 04:39:59 2018

Snav: Convert some legacy js-tests to testharness

Convert list:
snav-1st-stop
snav-aligned-not-aligned
snav-clipped-overflowed-content
snav-container-only-white-space
snav-container-white-space
snav-date

Bug: 803086
Change-Id: Id5723780293df17fd0c0020914630d2f1ea7d198
Reviewed-on: https://chromium-review.googlesource.com/1177527
Reviewed-by: Hugo Holgersson <hugoh@vewd.com>
Commit-Queue: JunHo Seo <junho0924.seo@lge.com>
Cr-Commit-Position: refs/heads/master@{#584651}
[delete] https://crrev.com/1307fc94c740509fda8af01d927ebd7109bf4856/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-1st-stop-expected.txt
[modify] https://crrev.com/fc8f959d596a079a55449b3ea84e7c63736a2a56/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-1st-stop.html
[delete] https://crrev.com/1307fc94c740509fda8af01d927ebd7109bf4856/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-aligned-not-aligned-expected.txt
[modify] https://crrev.com/fc8f959d596a079a55449b3ea84e7c63736a2a56/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-aligned-not-aligned.html
[delete] https://crrev.com/1307fc94c740509fda8af01d927ebd7109bf4856/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-clipped-overflowed-content-expected.txt
[modify] https://crrev.com/fc8f959d596a079a55449b3ea84e7c63736a2a56/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-clipped-overflowed-content.html
[delete] https://crrev.com/1307fc94c740509fda8af01d927ebd7109bf4856/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-container-only-white-space-expected.txt
[modify] https://crrev.com/fc8f959d596a079a55449b3ea84e7c63736a2a56/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-container-only-white-space.html
[delete] https://crrev.com/1307fc94c740509fda8af01d927ebd7109bf4856/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-container-white-space-expected.txt
[modify] https://crrev.com/fc8f959d596a079a55449b3ea84e7c63736a2a56/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-container-white-space.html
[delete] https://crrev.com/1307fc94c740509fda8af01d927ebd7109bf4856/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-date-expected.txt
[modify] https://crrev.com/fc8f959d596a079a55449b3ea84e7c63736a2a56/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-date.html

Currently our utility snav-testharness.js can't evaluate iframe test cases correctly. I think we can use verifyAndAdvance() in existing utility spatial-navigation-utils.js.
Some test cases have non-trivial post processing steps:
snav-input.html
snav-only-clipped-overflow-content.html
snav-radio-group.html
snav-textarea.html
snav-unit-overflow-and-scroll-in-direction.html

We need to convert these test cases carefully.
Some informative comments are cleaned in "Snav: Convert some legacy js-tests to testharness". I'll add it again.
Project Member

Comment 9 by bugdroid1@chromium.org, Aug 24

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/cf158e84abbeff2fe703affacf04281995afaab1

commit cf158e84abbeff2fe703affacf04281995afaab1
Author: JunHo Seo <junho0924.seo@lge.com>
Date: Fri Aug 24 05:12:59 2018

Snav: Convert some legacy js-tests to testharness - 2

Convert list:
snav-display-contents-crash
snav-div-in-anchor
snav-fully-aligned-horizontally
snav-fully-aligned-vertically
snav-hidden-focusable-element
snav-imagemap-area-not-focusable
snav-imagemap-area-without-image
snav-imagemap-overlapped-areas
snav-imagemap-simple
snav-media-elements

Bug: 803086

Change-Id: Iebe20bba5868fec1e1c38f2a188346432c42d568
Reviewed-on: https://chromium-review.googlesource.com/1184945
Reviewed-by: Hugo Holgersson <hugoh@vewd.com>
Commit-Queue: JunHo Seo <junho0924.seo@lge.com>
Cr-Commit-Position: refs/heads/master@{#585694}
[delete] https://crrev.com/041042ec03864e98d13a6b0649b05831e05fde8a/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-display-contents-crash-expected.txt
[modify] https://crrev.com/cf158e84abbeff2fe703affacf04281995afaab1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-display-contents-crash.html
[delete] https://crrev.com/041042ec03864e98d13a6b0649b05831e05fde8a/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-div-in-anchor-expected.txt
[modify] https://crrev.com/cf158e84abbeff2fe703affacf04281995afaab1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-div-in-anchor.html
[delete] https://crrev.com/041042ec03864e98d13a6b0649b05831e05fde8a/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-fully-aligned-horizontally-expected.txt
[modify] https://crrev.com/cf158e84abbeff2fe703affacf04281995afaab1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-fully-aligned-horizontally.html
[delete] https://crrev.com/041042ec03864e98d13a6b0649b05831e05fde8a/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-fully-aligned-vertically-expected.txt
[modify] https://crrev.com/cf158e84abbeff2fe703affacf04281995afaab1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-fully-aligned-vertically.html
[delete] https://crrev.com/041042ec03864e98d13a6b0649b05831e05fde8a/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-hidden-focusable-element-expected.txt
[modify] https://crrev.com/cf158e84abbeff2fe703affacf04281995afaab1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-hidden-focusable-element.html
[delete] https://crrev.com/041042ec03864e98d13a6b0649b05831e05fde8a/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-area-not-focusable-expected.txt
[modify] https://crrev.com/cf158e84abbeff2fe703affacf04281995afaab1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-area-not-focusable.html
[delete] https://crrev.com/041042ec03864e98d13a6b0649b05831e05fde8a/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-area-without-image-expected.txt
[modify] https://crrev.com/cf158e84abbeff2fe703affacf04281995afaab1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-area-without-image.html
[delete] https://crrev.com/041042ec03864e98d13a6b0649b05831e05fde8a/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-overlapped-areas-expected.txt
[modify] https://crrev.com/cf158e84abbeff2fe703affacf04281995afaab1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-overlapped-areas.html
[delete] https://crrev.com/041042ec03864e98d13a6b0649b05831e05fde8a/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-simple-expected.txt
[modify] https://crrev.com/cf158e84abbeff2fe703affacf04281995afaab1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-simple.html
[delete] https://crrev.com/041042ec03864e98d13a6b0649b05831e05fde8a/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-media-elements-expected.txt
[modify] https://crrev.com/cf158e84abbeff2fe703affacf04281995afaab1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-media-elements.html

Project Member

Comment 10 by bugdroid1@chromium.org, Aug 24

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/59df4e9c018d4081728eadcaf1138d49140b65ca

commit 59df4e9c018d4081728eadcaf1138d49140b65ca
Author: JunHo Seo <junho0924.seo@lge.com>
Date: Fri Aug 24 09:23:14 2018

Revert "Snav: Convert some legacy js-tests to testharness - 2"

This reverts commit cf158e84abbeff2fe703affacf04281995afaab1.

Reason for revert: A converted test snav-media-elements.html becomes flaky

Original change's description:
> Snav: Convert some legacy js-tests to testharness - 2
> 
> Convert list:
> snav-display-contents-crash
> snav-div-in-anchor
> snav-fully-aligned-horizontally
> snav-fully-aligned-vertically
> snav-hidden-focusable-element
> snav-imagemap-area-not-focusable
> snav-imagemap-area-without-image
> snav-imagemap-overlapped-areas
> snav-imagemap-simple
> snav-media-elements
> 
> Bug: 803086
> 
> Change-Id: Iebe20bba5868fec1e1c38f2a188346432c42d568
> Reviewed-on: https://chromium-review.googlesource.com/1184945
> Reviewed-by: Hugo Holgersson <hugoh@vewd.com>
> Commit-Queue: JunHo Seo <junho0924.seo@lge.com>
> Cr-Commit-Position: refs/heads/master@{#585694}

TBR=kochi@chromium.org,szager@chromium.org,junho0924.seo@lge.com,hugoh@vewd.com

Change-Id: Id2448339f31a707ed9f6c769cd71dec0d500d11c
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Bug: 803086
Reviewed-on: https://chromium-review.googlesource.com/1188262
Reviewed-by: Hugo Holgersson <hugoh@vewd.com>
Commit-Queue: JunHo Seo <junho0924.seo@lge.com>
Cr-Commit-Position: refs/heads/master@{#585774}
[add] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-display-contents-crash-expected.txt
[modify] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-display-contents-crash.html
[add] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-div-in-anchor-expected.txt
[modify] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-div-in-anchor.html
[add] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-fully-aligned-horizontally-expected.txt
[modify] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-fully-aligned-horizontally.html
[add] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-fully-aligned-vertically-expected.txt
[modify] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-fully-aligned-vertically.html
[add] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-hidden-focusable-element-expected.txt
[modify] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-hidden-focusable-element.html
[add] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-area-not-focusable-expected.txt
[modify] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-area-not-focusable.html
[add] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-area-without-image-expected.txt
[modify] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-area-without-image.html
[add] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-overlapped-areas-expected.txt
[modify] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-overlapped-areas.html
[add] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-simple-expected.txt
[modify] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-simple.html
[add] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-media-elements-expected.txt
[modify] https://crrev.com/59df4e9c018d4081728eadcaf1138d49140b65ca/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-media-elements.html

Project Member

Comment 11 by bugdroid1@chromium.org, Aug 24

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/64440a46c370db1c91083e21dfb9176ee60944df

commit 64440a46c370db1c91083e21dfb9176ee60944df
Author: Hugo Holgersson <hugoh@vewd.com>
Date: Fri Aug 24 15:50:52 2018

Snav: Assert focus at keyup, not at setTimout(0, ...)

"... the default action MUST be to shift the document focus".
https://www.w3.org/TR/uievents/#event-type-keydown

As focus movement happens during keydown, once we got the
succeeding keyup-event, it's safe to assert activeElement.

Why not do the asserts at 'focusin' instead?
After 'keyup', we're safe to send another trigger-key.
(Most spatnav tests verify several focus movements).

Bug: 803086
Change-Id: I6927d61a9d323f5bd3fe8a6022aef2f6eca50521
Reviewed-on: https://chromium-review.googlesource.com/1188476
Reviewed-by: Fredrik Söderquist <fs@opera.com>
Commit-Queue: Hugo Holgersson <hugoh@vewd.com>
Cr-Commit-Position: refs/heads/master@{#585855}
[modify] https://crrev.com/64440a46c370db1c91083e21dfb9176ee60944df/third_party/WebKit/LayoutTests/fast/spatial-navigation/resources/snav-testharness.js

Project Member

Comment 13 by bugdroid1@chromium.org, Aug 29

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/a616c91aef808bb17fb4214884f6218a5a04e965

commit a616c91aef808bb17fb4214884f6218a5a04e965
Author: JunHo Seo <junho0924.seo@lge.com>
Date: Wed Aug 29 01:38:07 2018

Snav: Fix flaky test snav-div-overflow-scrol-hidden

In snav-testharness.js, we have more deterministic testing steps
for snav test cases. So by converting this to testharness.js, it seems
we can remove flakiness of the test case.
But this CL is still speculative, because it was not verified sufficiently
on flaky environment(Mac).
In addition, file name is fixed.

Bug:  688515 , 803086
Change-Id: Ifd1bbe730e3ba189e28a5789500f35ded301680e
Reviewed-on: https://chromium-review.googlesource.com/1186202
Reviewed-by: Hugo Holgersson <hugoh@vewd.com>
Commit-Queue: JunHo Seo <junho0924.seo@lge.com>
Cr-Commit-Position: refs/heads/master@{#586986}
[modify] https://crrev.com/a616c91aef808bb17fb4214884f6218a5a04e965/third_party/WebKit/LayoutTests/TestExpectations
[delete] https://crrev.com/8ca10fb2914087fd1b2589dedf69f615595bdb4c/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-div-overflow-scrol-hidden-expected.txt
[delete] https://crrev.com/8ca10fb2914087fd1b2589dedf69f615595bdb4c/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-div-overflow-scrol-hidden.html
[add] https://crrev.com/a616c91aef808bb17fb4214884f6218a5a04e965/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-div-overflow-scroll-hidden.html

Project Member

Comment 14 by bugdroid1@chromium.org, Aug 29

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/9bc66a1070128a8e3344ae0acf9d8eb43460feb0

commit 9bc66a1070128a8e3344ae0acf9d8eb43460feb0
Author: JunHo Seo <junho0924.seo@lge.com>
Date: Wed Aug 29 02:27:59 2018

Reland "Snav: Convert some legacy js-tests to testharness - 2"

This is a reland of cf158e84abbeff2fe703affacf04281995afaab1
By https://chromium-review.googlesource.com/c/chromium/src/+/1188476 ,
we have more deterministic testing steps.

Original change's description:
> Snav: Convert some legacy js-tests to testharness - 2
>
> Convert list:
> snav-display-contents-crash
> snav-div-in-anchor
> snav-fully-aligned-horizontally
> snav-fully-aligned-vertically
> snav-hidden-focusable-element
> snav-imagemap-area-not-focusable
> snav-imagemap-area-without-image
> snav-imagemap-overlapped-areas
> snav-imagemap-simple
> snav-media-elements
>
> Bug: 803086
>
> Change-Id: Iebe20bba5868fec1e1c38f2a188346432c42d568
> Reviewed-on: https://chromium-review.googlesource.com/1184945
> Reviewed-by: Hugo Holgersson <hugoh@vewd.com>
> Commit-Queue: JunHo Seo <junho0924.seo@lge.com>
> Cr-Commit-Position: refs/heads/master@{#585694}

Bug: 803086
Change-Id: Ie55c9fb182551e826c9698c9321a88adfb8e7616
Reviewed-on: https://chromium-review.googlesource.com/1188263
Commit-Queue: JunHo Seo <junho0924.seo@lge.com>
Reviewed-by: Hugo Holgersson <hugoh@vewd.com>
Cr-Commit-Position: refs/heads/master@{#586999}
[modify] https://crrev.com/9bc66a1070128a8e3344ae0acf9d8eb43460feb0/third_party/WebKit/LayoutTests/fast/spatial-navigation/resources/snav-testharness.js
[delete] https://crrev.com/943d3f6eaeaea6b614c7cce17b3b3335104bfbc1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-display-contents-crash-expected.txt
[modify] https://crrev.com/9bc66a1070128a8e3344ae0acf9d8eb43460feb0/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-display-contents-crash.html
[delete] https://crrev.com/943d3f6eaeaea6b614c7cce17b3b3335104bfbc1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-div-in-anchor-expected.txt
[modify] https://crrev.com/9bc66a1070128a8e3344ae0acf9d8eb43460feb0/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-div-in-anchor.html
[delete] https://crrev.com/943d3f6eaeaea6b614c7cce17b3b3335104bfbc1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-fully-aligned-horizontally-expected.txt
[modify] https://crrev.com/9bc66a1070128a8e3344ae0acf9d8eb43460feb0/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-fully-aligned-horizontally.html
[delete] https://crrev.com/943d3f6eaeaea6b614c7cce17b3b3335104bfbc1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-fully-aligned-vertically-expected.txt
[modify] https://crrev.com/9bc66a1070128a8e3344ae0acf9d8eb43460feb0/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-fully-aligned-vertically.html
[delete] https://crrev.com/943d3f6eaeaea6b614c7cce17b3b3335104bfbc1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-hidden-focusable-element-expected.txt
[modify] https://crrev.com/9bc66a1070128a8e3344ae0acf9d8eb43460feb0/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-hidden-focusable-element.html
[delete] https://crrev.com/943d3f6eaeaea6b614c7cce17b3b3335104bfbc1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-area-not-focusable-expected.txt
[modify] https://crrev.com/9bc66a1070128a8e3344ae0acf9d8eb43460feb0/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-area-not-focusable.html
[delete] https://crrev.com/943d3f6eaeaea6b614c7cce17b3b3335104bfbc1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-area-without-image-expected.txt
[modify] https://crrev.com/9bc66a1070128a8e3344ae0acf9d8eb43460feb0/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-area-without-image.html
[delete] https://crrev.com/943d3f6eaeaea6b614c7cce17b3b3335104bfbc1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-overlapped-areas-expected.txt
[modify] https://crrev.com/9bc66a1070128a8e3344ae0acf9d8eb43460feb0/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-overlapped-areas.html
[delete] https://crrev.com/943d3f6eaeaea6b614c7cce17b3b3335104bfbc1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-simple-expected.txt
[modify] https://crrev.com/9bc66a1070128a8e3344ae0acf9d8eb43460feb0/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-imagemap-simple.html
[delete] https://crrev.com/943d3f6eaeaea6b614c7cce17b3b3335104bfbc1/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-media-elements-expected.txt
[modify] https://crrev.com/9bc66a1070128a8e3344ae0acf9d8eb43460feb0/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-media-elements.html

Project Member

Comment 15 by bugdroid1@chromium.org, Sep 4

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/a1cdbbb544c358e70f7475dac02ee23f1897dfd3

commit a1cdbbb544c358e70f7475dac02ee23f1897dfd3
Author: Hugo Holgersson <hugoh@vewd.com>
Date: Tue Sep 04 11:59:18 2018

Snav: Make snav-stay-in-overflow-div.html use snav-testharness.js

This fixes a flakiness that has been haunting this
test for a while. It used to flake ~ 4/100 times:

$ python third_party/WebKit/Tools/Scripts/run-webkit-tests
   --repeat-each=100 -t Release
   LayoutTests/fast/spatial-navigation/snav-stay-in-overflow-div.html

Now, even 1000 runs pass.

snav-testharness.js does not use requestAnimationFrame().
The old helper, spatial-navigation-utils.js, did.
Different rAF-timings probably caused the flakiness.

Bug: 803086,  871416 
Change-Id: Idbf0bfb544236ba1a77986c7d62200b2e17d6884
Reviewed-on: https://chromium-review.googlesource.com/1185188
Commit-Queue: Hugo Holgersson <hugoh@vewd.com>
Reviewed-by: Fredrik Söderquist <fs@opera.com>
Cr-Commit-Position: refs/heads/master@{#588491}
[modify] https://crrev.com/a1cdbbb544c358e70f7475dac02ee23f1897dfd3/third_party/WebKit/LayoutTests/TestExpectations
[delete] https://crrev.com/b9916fe70686f0bec51f442265120949ae2281ed/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-stay-in-overflow-div-expected.txt
[modify] https://crrev.com/a1cdbbb544c358e70f7475dac02ee23f1897dfd3/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-stay-in-overflow-div.html

Comment 16 Deleted

Comment 17 Deleted

Project Member

Comment 18 by bugdroid1@chromium.org, Oct 3

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/071662140c49d1dc5d9758bd17b867e2533b593e

commit 071662140c49d1dc5d9758bd17b867e2533b593e
Author: Hugo Holgersson <hugoh@vewd.com>
Date: Wed Oct 03 14:26:36 2018

Snav: Convert snav-two-elements-one-line.html to snav-testharness.js

With snav-testharness.js, the flakiness seen in  Issue 836275  will
most probably be gone.

Bug: 803086,  836275 
Change-Id: If44b1ca5c88af3c0fcc045061cdce50dcc91a276
Reviewed-on: https://chromium-review.googlesource.com/c/1257919
Reviewed-by: Fredrik Söderquist <fs@opera.com>
Commit-Queue: Hugo Holgersson <hugoh@vewd.com>
Cr-Commit-Position: refs/heads/master@{#596206}
[modify] https://crrev.com/071662140c49d1dc5d9758bd17b867e2533b593e/third_party/WebKit/LayoutTests/TestExpectations
[delete] https://crrev.com/eff4e8012e1be8eb0e95b51799a72b8225a5aed5/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-two-elements-one-line-expected.txt
[modify] https://crrev.com/071662140c49d1dc5d9758bd17b867e2533b593e/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-two-elements-one-line.html

Project Member

Comment 19 by bugdroid1@chromium.org, Oct 4

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/5223c5c89cdef4918cd52d907148ab91a379f7bd

commit 5223c5c89cdef4918cd52d907148ab91a379f7bd
Author: Hugo Holgersson <hugoh@vewd.com>
Date: Thu Oct 04 06:51:03 2018

Snav: Convert snav-only-clipped-overflow-content.html to snav-testharness.js

Let's also assert focus movements to the other focusables. Previously,
the only thing this test tested was that DOWN would _not_ move focus...

Once we've fixed  Issue 801162 , this test's expectations will change:
We want spatnav to first _focus_ the scroller (before scrolling it).

Bug: 803086,  801162 
Change-Id: I5c8a964c2900fb3a550a55ba9a975c7a33ef42dd
Reviewed-on: https://chromium-review.googlesource.com/c/1257832
Commit-Queue: Hugo Holgersson <hugoh@vewd.com>
Reviewed-by: Fredrik Söderquist <fs@opera.com>
Cr-Commit-Position: refs/heads/master@{#596527}
[delete] https://crrev.com/2aba1b0d18473ad68ca3cecb81836253e33fe5d9/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-only-clipped-overflow-content-expected.txt
[modify] https://crrev.com/5223c5c89cdef4918cd52d907148ab91a379f7bd/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-only-clipped-overflow-content.html

Project Member

Comment 20 by bugdroid1@chromium.org, Nov 2

The following revision refers to this bug:
  https://chromium.googlesource.com/chromium/src.git/+/a417a16cbf123394a09dc3ee985591da1b5301ed

commit a417a16cbf123394a09dc3ee985591da1b5301ed
Author: Hugo Holgersson <hugoh@vewd.com>
Date: Fri Nov 02 17:01:10 2018

Snav: Convert all snav*iframe*.html tests to snav-testharness.js

The changes to snav-testharness.js lets us assert navigations
in and out of iframes:

 1) To be able to test focus movements in and out of iframes,
    we need to listen for 'keyup'-events on the document where
    focus is _about_to_go_.

    'keyup' targets the currently focused document. When 'keyup'
    comes, 'keydown' has already changed focus to the new document.

 2) Previously each movement had its own async_test(). Now we use
    one async_test() with many "test steps": one for each movement.
    This helps us avoid tricky (mis)usage of testharness.js's
    fetch_tests_from_window().

The changes to the HTML files are mostly mechanical except that
I gave some elements new or renamed ids so they become easier
to distinguish when debugging.

Once we've fixed  Issue 801162 , the tests' expectations will change:
We want spatnav to first _focus_ the iframe (before scrolling it
or searching inside of it).

Bug: 803086,  891658 ,  801162 
Change-Id: Ib53bb224398510b5744927a5d892381870fa4690
Reviewed-on: https://chromium-review.googlesource.com/c/1314469
Commit-Queue: Hugo Holgersson <hugoh@vewd.com>
Reviewed-by: Fredrik Söderquist <fs@opera.com>
Cr-Commit-Position: refs/heads/master@{#604962}
[delete] https://crrev.com/4dea3aba8069abf0688bef434173cc620ce87139/third_party/WebKit/LayoutTests/fast/spatial-navigation/resources/iframe.html
[modify] https://crrev.com/a417a16cbf123394a09dc3ee985591da1b5301ed/third_party/WebKit/LayoutTests/fast/spatial-navigation/resources/snav-testharness.js
[delete] https://crrev.com/4dea3aba8069abf0688bef434173cc620ce87139/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-iframe-nested-expected.txt
[modify] https://crrev.com/a417a16cbf123394a09dc3ee985591da1b5301ed/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-iframe-nested.html
[delete] https://crrev.com/4dea3aba8069abf0688bef434173cc620ce87139/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-iframe-no-focusable-content-expected.txt
[modify] https://crrev.com/a417a16cbf123394a09dc3ee985591da1b5301ed/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-iframe-no-focusable-content.html
[delete] https://crrev.com/4dea3aba8069abf0688bef434173cc620ce87139/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-iframe-no-scrollable-content-expected.txt
[modify] https://crrev.com/a417a16cbf123394a09dc3ee985591da1b5301ed/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-iframe-no-scrollable-content.html
[delete] https://crrev.com/4dea3aba8069abf0688bef434173cc620ce87139/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-iframe-recursive-offset-parent-expected.txt
[modify] https://crrev.com/a417a16cbf123394a09dc3ee985591da1b5301ed/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-iframe-recursive-offset-parent.html
[delete] https://crrev.com/4dea3aba8069abf0688bef434173cc620ce87139/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-iframe-with-offscreen-focusable-element-expected.txt
[modify] https://crrev.com/a417a16cbf123394a09dc3ee985591da1b5301ed/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-iframe-with-offscreen-focusable-element.html
[delete] https://crrev.com/4dea3aba8069abf0688bef434173cc620ce87139/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-iframe-with-outside-focusable-element-expected.txt
[modify] https://crrev.com/a417a16cbf123394a09dc3ee985591da1b5301ed/third_party/WebKit/LayoutTests/fast/spatial-navigation/snav-iframe-with-outside-focusable-element.html

Let's handle about promise based test at here:
https://chromium-review.googlesource.com/c/chromium/src/+/960185/14/third_party/blink/web_tests/fast/spatial-navigation/snav-search-focused-offscreen-scroller.html#34

let notScrolled = async_test( ... ) 
snav.assertFocusMoves(resultMap).then(function() {
  notScrolled.step_func_done(function() {
    assert_equals(start.scrollTop, 0);
  });
});
Thanks. Having assertFocusMoves return a Promise was just a suggestion. No rush with that. :) It might be too complicated anyway.
Cc: hu...@vewd.com
Owner: ----
Status: Available (was: Started)
Summary: Replace spatial-navigation-utils.js with snav-testharness.js (was: Port spatial-navigation-utils.js to testharness.js)

Sign in to add a comment