New issue
Advanced search Search tips

Issue 802929 link

Starred by 2 users

Issue metadata

Status: Started
Owner:
Components:
EstimatedDays: ----
NextAction: ----
OS: ----
Pri: 2
Type: Bug

Blocking:
issue 497851


Participants' hotlists:
Snap-Points-Post-Ship-Tasks


Sign in to add a comment

[css-scroll-snap] Add additional wpt tests for snap points

Project Member Reported by sunyunjia@chromium.org, Jan 17 2018

Issue description

To get ready for shipping this feature, we need to add its layout-test to web-platform-test.
 
Blocking: 497851
Summary: [css-scroll-snap] Add layout-test for CSSScrollSnapPoints (was: Add layout-test for CSSScrollSnapPoints)
Our layout tests now live in wpt/css/css-scroll-snap and a few in wpt/css/cssom-view


Here is the current state of our tests:
- css-scroll-snap/snap-at-user-scroll-end-manual.html: ensure basic snap occurs after user scrolling (automated in Chrome)  
- css-scroll-snap/scroll-snap-type-proximity.html: covers basic impact of proximity.  TODO: This has some assumption in there which may be chrome specific. 
- css-scroll-snap/scrollTo-scrollBy-snaps.html:  covers setting scroll position via setters, scrollBy, scrollTo on viewport and non-viewport elements
- css-scroll-snap/snap-inline-block.html: checks that start|end are correctly interpreted in different wirting modes
- css-scroll-snap/snap-to-visible-areas.html: checks that we satisfy visibility requirement

- cssom-view/scrollIntoView-scrollPadding.html: ensure sIV correctly considers scroll-padding
- cssom-view/scrollIntoView-scrollMargin.html: same as above for scroll-margin


We also have some unit tests for key logic:
- https://codesearch.chromium.org/chromium/src/third_party/blink/renderer/core/page/scrolling/snap_coordinator_test.cc
Areas we are missing tests:
- impact of visual viewport (e.g., pinch zoom) on viewport snapping. Not sure how much this is web exposed. It may be that we cannot have this in wpt. 
- impact of transform on computes snap offset
- keyboard scrolling  particularly page down and page up and other semantic scrolling
- tests to ensure we don't lock user in a point if there are largely space snap points

anything else?

Areas we can improve our current tests:
- exercise css-scroll-snap/snap-at-user-scroll-end-manual.html with other user input types.
- most of margin/padding/alignment calc are in unit tests we should make a version of these as wpt test.
- cssom-view/scrollIntoView-scrollPadding.html can easily be ported to cover
  focus() and URL #anchor scrolling. Thanks to fantasia there is already a PR that does some of this. Maybe wait for it to land :). https://github.com/w3c/web-platform-tests/pull/8575
Summary: [css-scroll-snap] Add additional wpt tests for snap points (was: [css-scroll-snap] Add layout-test for CSSScrollSnapPoints)

Sign in to add a comment