Bug 171634 - Change the asynchronous image decoding tests to use the event webkitImageFrameReady
Summary: Change the asynchronous image decoding tests to use the event webkitImageFram...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Images (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Said Abou-Hallawa
URL:
Keywords: InRadar
Depends on: 171641 171694
Blocks:
  Show dependency treegraph
 
Reported: 2017-05-03 16:41 PDT by Said Abou-Hallawa
Modified: 2017-05-04 18:53 PDT (History)
4 users (show)

See Also:


Attachments
Patch (19.90 KB, patch)
2017-05-03 16:48 PDT, Said Abou-Hallawa
no flags Details | Formatted Diff | Diff
Patch (9.55 KB, patch)
2017-05-04 17:13 PDT, Said Abou-Hallawa
no flags Details | Formatted Diff | Diff
Patch (9.53 KB, patch)
2017-05-04 17:29 PDT, Said Abou-Hallawa
no flags Details | Formatted Diff | Diff
Patch (9.43 KB, patch)
2017-05-04 18:12 PDT, Said Abou-Hallawa
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Said Abou-Hallawa 2017-05-03 16:41:37 PDT
TestRunner.display() needs to have the option to draw the web page without drawing a gray background for the track repaints. A new argument will be added to this function to provide this option but it is optional. If it is not passed, it will behave as it was before the change so the existing tests won't break.

The purpose of this change is to make it easy to test the async image decoding. To draw an image asynchronously, TestRunner.display() will be called to start the image decoding. When the image frame is ready, we are going to call TestRunner.notifyDone() which will call TestRunner.display() a second time. This time, the image will be drawn without any further decoding.
Comment 1 Said Abou-Hallawa 2017-05-03 16:48:36 PDT
Created attachment 308986 [details]
Patch
Comment 2 Radar WebKit Bug Importer 2017-05-03 16:55:08 PDT
<rdar://problem/31976651>
Comment 3 Simon Fraser (smfr) 2017-05-03 16:59:24 PDT
Maybe we should just rename display() to displayAndTrackRepaints()? There are 175 instances:

compositing/clip-change.html:        testRunner.display();
compositing/geometry/foreground-offset-change.html:        testRunner.display();
compositing/geometry/limit-layer-bounds-transformed-overflow.html:        testRunner.display();
compositing/iframes/become-composited-nested-iframes.html:              testRunner.display();
compositing/iframes/become-overlapped-iframe.html:                testRunner.display(); // Painting has to happen to detect overlap.
compositing/iframes/connect-compositing-iframe-delayed.html:            testRunner.display();
compositing/iframes/connect-compositing-iframe.html:        testRunner.display();
compositing/iframes/connect-compositing-iframe2.html:            testRunner.display();
compositing/iframes/connect-compositing-iframe3.html:        testRunner.display();
compositing/iframes/enter-compositing-iframe.html:        testRunner.display();
compositing/iframes/iframe-content-flipping.html:        testRunner.display();
compositing/iframes/iframe-resize.html:            testRunner.display();
compositing/iframes/iframe-resize.html:                testRunner.display();
compositing/iframes/iframe-size-to-zero.html:                testRunner.display();
compositing/iframes/iframe-size-to-zero.html:                testRunner.display();
compositing/iframes/iframe-src-change.html:                testRunner.display(); // Need to paint for overlap testing.
compositing/iframes/invisible-nested-iframe-hide.html:          testRunner.display();
compositing/iframes/invisible-nested-iframe-show.html:          testRunner.display();
compositing/iframes/leave-compositing-iframe.html:        testRunner.display();
compositing/iframes/overlapped-iframe-iframe.html:                testRunner.display();
compositing/iframes/overlapped-iframe.html:              testRunner.display();
compositing/iframes/overlapped-nested-iframes.html:            testRunner.display();
compositing/iframes/repaint-after-losing-scrollbars.html:        testRunner.display(); // Paint once with all overflow controls visible.
compositing/iframes/resources/fixed-position-subframe.html:            testRunner.display();
compositing/iframes/resources/fixed-position-transformed-subframe.html:        testRunner.display();
compositing/iframes/resources/scrollgrandchild-inner.html:        testRunner.display();
compositing/iframes/scrolling-iframe.html:                testRunner.display();
compositing/overflow/content-gains-scrollbars.html:        testRunner.display(); // Ensure compositor tree is up to date.
compositing/overflow/content-gains-scrollbars.html:    testRunner.display(); // Force compositor state to be updated before the container needs any overflow controls
compositing/overflow/content-loses-scrollbars.html:        testRunner.display(); // Ensure compositor tree is up to date.
compositing/overflow/content-loses-scrollbars.html:    testRunner.display(); // Force compositor state to be updated before the container needs any overflow controls
compositing/overflow/do-not-paint-outline-into-composited-scrolling-contents.html:        window.testRunner.display();
compositing/overflow/overflow-scrollbar-layers.html:    testRunner.display(); // Ensure compositor tree is up to date.
compositing/overflow/paint-neg-z-order-descendants-into-scrolling-contents-layer.html:      window.testRunner.display();
compositing/overflow/paint-neg-z-order-descendants-into-scrolling-contents-layer.html:        window.testRunner.display();
compositing/overflow/repaint-after-losing-scrollbars.html:    testRunner.display(); // Paint once with all overflow controls visible.
compositing/patterns/direct-pattern-compositing-add-text-expected.html:              testRunner.display();
compositing/patterns/direct-pattern-compositing-add-text.html:              testRunner.display();
compositing/patterns/direct-pattern-compositing-change-expected.html:              window.testRunner.display();
compositing/patterns/direct-pattern-compositing-change.html:              window.testRunner.display();
compositing/patterns/direct-pattern-compositing-load-expected.html:              window.testRunner.display();
compositing/patterns/direct-pattern-compositing-load.html:              window.testRunner.display();
compositing/plugins/invalidate_rect.html:      testRunner.display();
compositing/repaint/iframes/composited-iframe-with-fixed-background-doc-repaint.html:                testRunner.display(); // Flush pending compositing repaints.
compositing/repaint/iframes/compositing-iframe-scroll-repaint.html:                testRunner.display(); // Flush pending compositing repaints.
compositing/repaint/iframes/compositing-iframe-with-fixed-background-doc-repaint.html:                testRunner.display(); // Flush pending compositing repaints.
compositing/repaint/newly-composited-on-scroll.html:            testRunner.display();
compositing/repaint/newly-composited-on-scroll.html:            testRunner.display();
compositing/repaint/newly-composited-repaint-rect.html:            testRunner.display();
compositing/repaint/page-scale-repaint.html:        testRunner.display();
compositing/repaint/requires-backing-repaint.html:                testRunner.display();
compositing/repaint/transform-style-change.html:    testRunner.display(); // Force one composite with preserve-3d
compositing/rtl/rtl-overflow-invalidation.html:            testRunner.display();
compositing/scroll-painted-composited-content.html:            testRunner.display();
compositing/tiling/huge-layer-resize.html:            testRunner.display();
compositing/video/video-with-invalid-source.html:            testRunner.display();
compositing/video-page-visibility.html:        testRunner.display();
compositing/video-page-visibility.html:        testRunner.display();
compositing/webgl/webgl-repaint.html:      testRunner.display();
compositing/webgl/webgl-repaint.html:      testRunner.display();
compositing/webgl/webgl-repaint.html:      testRunner.display();
css3/filters/multiple-filters-invalidation.html:    testRunner.display();
css3/flexbox/repaint-column-reverse.html:        testRunner.display();
css3/flexbox/repaint-during-resize-no-flex.html:        testRunner.display();
css3/flexbox/repaint-rtl-column.html:        testRunner.display();
css3/flexbox/repaint.html:        testRunner.display();
displaylists/canvas-display-list.html:                testRunner.display();
displaylists/resources/dump-target-display-list.js:        testRunner.display();
displaylists/resources/dump-target-replay-list.js:        testRunner.display();
fast/animation/request-animation-frame-detach-element.html:            testRunner.display();
fast/animation/request-animation-frame-detach-element2.html:            testRunner.display();
fast/animation/request-animation-frame-during-modal.html:              '    testRunner.display();' +
fast/animation/request-animation-frame-during-modal.html:        testRunner.display();
fast/animation/request-animation-frame-iframe.html:                testRunner.display();
fast/animation/request-animation-frame-iframe2.html:                testRunner.display();
fast/animation/script-tests/request-animation-frame-cancel.js:    testRunner.display();
fast/animation/script-tests/request-animation-frame-cancel2.js:    testRunner.display();
fast/animation/script-tests/request-animation-frame-disabled.js:    testRunner.display();
fast/animation/script-tests/request-animation-frame-prefix.js:        testRunner.display();
fast/animation/script-tests/request-animation-frame-prefix.js:        testRunner.display();
fast/animation/script-tests/request-animation-frame-time-unit.js:            testRunner.display();
fast/animation/script-tests/request-animation-frame-time-unit.js:    testRunner.display();
fast/animation/script-tests/request-animation-frame-timestamps-advance.js:        testRunner.display();
fast/animation/script-tests/request-animation-frame-timestamps-advance.js:        testRunner.display();
fast/animation/script-tests/request-animation-frame-timestamps.js:    testRunner.display();
fast/animation/script-tests/request-animation-frame-within-callback.js:    testRunner.display();
fast/animation/script-tests/request-animation-frame-within-callback.js:    testRunner.display();
fast/animation/script-tests/request-animation-frame.js:    testRunner.display();
fast/backgrounds/obscured-background-child-style-change-expected.html:    testRunner.display();
fast/backgrounds/obscured-background-child-style-change.html:    testRunner.display();
fast/backgrounds/solid-color-context-restore.html:            testRunner.display();
fast/canvas/canvas-as-image-incremental-repaint.html:        testRunner.display();
fast/canvas/canvas-incremental-repaint-2.html:            testRunner.display();
fast/canvas/canvas-incremental-repaint.html:            testRunner.display();
fast/canvas/canvas-resize-after-paint.html:    testRunner.display(); // Force a composite at normal width/height to ensure we have a compositing layer for the canvas.
fast/canvas/resources/repaint.js:        testRunner.display();
fast/canvas/script-tests/canvas-imageSmoothingEnabled-repaint.js:        testRunner.display();
fast/canvas/webgl/canvas-test.html:      testRunner.display();
fast/canvas/webgl/webgl-layer-update.html:            testRunner.display();
fast/canvas/webgl/webgl-layer-update.html:    testRunner.display();
fast/css/pseudostyle-anonymous-text.html:                testRunner.display();
fast/css/relative-positioned-block-crash.html:            testRunner.display();
fast/dom/Window/post-message-crash.html:    testRunner.display();
fast/dom/Window/web-timing-minimal-performance-now.html:    window.testRunner.display();
fast/dynamic/containing-block-change.html:            testRunner.display();
fast/dynamic/containing-block-change.html:            testRunner.display();
fast/dynamic/layer-no-longer-paginated.html:            testRunner.display();
fast/events/touch/gesture/pad-gesture-cancel.js:    testRunner.display();
fast/events/touch/gesture/pad-gesture-fling.js:    testRunner.display();
fast/events/touch/gesture/pad-gesture-fling.js:    testRunner.display();
fast/events/touch/gesture/pad-gesture-fling.js:    testRunner.display();
fast/forms/hidden-listbox.html:    testRunner.display();
fast/forms/listbox-clip.html:            testRunner.display();
fast/frames/inline-object-inside-frameset.html:        testRunner.display();
fast/frames/transparent-scrollbar.html:        testRunner.display();
fast/frames/transparent-scrollbar.html:            testRunner.display();
fast/images/animated-background-image-crash.html:                testRunner.display();
fast/layers/add-layer-with-nested-stacking.html:        testRunner.display();
fast/layers/inline-dirty-z-order-lists.html:        testRunner.display();
fast/layers/layer-content-visibility-change.html:        testRunner.display();
fast/layers/nested-layers-1.html:        testRunner.display();
fast/layers/nested-layers-2.html:        testRunner.display();
fast/layers/nested-layers-3.html:        testRunner.display();
fast/layers/nested-layers-4.html:        testRunner.display();
fast/layers/remove-layer-with-nested-stacking.html:        testRunner.display();
fast/overflow/hidden-scrollbar-resize.html:    testRunner.display();
fast/reflections/inline-crash.html:            testRunner.display();
fast/repaint/animation-after-layer-scroll.html:        testRunner.display();
fast/repaint/animation-after-layer-scroll.html:        testRunner.display();
fast/repaint/background-shorthand-with-gradient-and-height-changes.html:    window.testRunner.display();
fast/repaint/fixed-child-move-after-scroll.html:              testRunner.display();
fast/repaint/fixed-child-of-fixed-move-after-scroll.html:              testRunner.display();
fast/repaint/fixed-child-of-transformed-move-after-scroll.html:              testRunner.display();
fast/repaint/fixed-move-after-scroll.html:              testRunner.display();
fast/repaint/no-animation-outside-viewport-subframe.html:        testRunner.display();
fast/repaint/no-animation-outside-viewport-subframe.html:        testRunner.display();
fast/repaint/no-animation-outside-viewport.html:        testRunner.display();
fast/repaint/obscured-background-no-repaint.html:        testRunner.display();
fast/repaint/overflow-hidden-in-overflow-hidden-scrolled.html:                testRunner.display();
fast/repaint/renderer-destruction-by-invalidateSelection-crash.html:            testRunner.display();
fast/repaint/repaint-during-scroll-with-zoom.html:            testRunner.display();
fast/repaint/resources/fixed-move-after-keyboard-scroll-iframe.html:              testRunner.display();
fast/repaint/resources/iframe-scroll-repaint-iframe.html:    testRunner.display();
fast/repaint/resources/line-flow-with-floats.js:        testRunner.display();
fast/repaint/resources/repaint.js:        testRunner.display();
fast/repaint/table-overflow-hidden-in-overflow-hidden-scrolled.html:                testRunner.display();
fast/replaced/width100percent-textarea.html:    testRunner.display();
fast/scrolling/scrollbar-tickmarks-hittest.html:        testRunner.display();
fast/table/border-collapsing/cached-69296.html:                    testRunner.display();
fast/table/border-collapsing/cached-cell-append.html:                    testRunner.display();
fast/table/border-collapsing/cached-cell-remove.html:                    testRunner.display();
fast/table/border-collapsing/cached-change-cell-border-color.html:                    testRunner.display();
fast/table/border-collapsing/cached-change-cell-border-width.html:                    testRunner.display();
fast/table/border-collapsing/cached-change-cell-sl-border-color.html:                    testRunner.display();
fast/table/border-collapsing/cached-change-col-border-color.html:                    testRunner.display();
fast/table/border-collapsing/cached-change-col-border-width.html:                    testRunner.display();
fast/table/border-collapsing/cached-change-colgroup-border-color.html:                    testRunner.display();
fast/table/border-collapsing/cached-change-colgroup-border-width.html:                    testRunner.display();
fast/table/border-collapsing/cached-change-row-border-color.html:                    testRunner.display();
fast/table/border-collapsing/cached-change-row-border-width.html:                    testRunner.display();
fast/table/border-collapsing/cached-change-table-border-color.html:                    testRunner.display();
fast/table/border-collapsing/cached-change-table-border-width.html:                    testRunner.display();
fast/table/border-collapsing/cached-change-tbody-border-color.html:                    testRunner.display();
fast/table/border-collapsing/cached-change-tbody-border-width.html:                    testRunner.display();
fast/table/empty-section-crash.html:            testRunner.display();
fast/text/font-initial.html:        testRunner.display();
fast/text/international/harfbuzz-runs-with-no-glyph.html:    testRunner.display();
fast/text/text-shadow-extreme-value.html:        testRunner.display();
http/tests/misc/slow-loading-image-in-pattern.html:    testRunner.display();
media/audio-repaint.html:        testRunner.display();
media/media-document-audio-repaint.html:            testRunner.display();
scrollbars/scrollbar-percent-padding-crash.html:        testRunner.display();
svg/custom/non-scaling-stroke-update.svg:        testRunner.display();
svg/custom/stale-resource-data-crash.svg:      testRunner.display();
Comment 4 Simon Fraser (smfr) 2017-05-04 11:26:55 PDT
I think the new way is bug 171641, right?
Comment 5 Said Abou-Hallawa 2017-05-04 17:13:04 PDT
Created attachment 309116 [details]
Patch
Comment 6 Said Abou-Hallawa 2017-05-04 17:29:35 PDT
Created attachment 309117 [details]
Patch
Comment 7 Simon Fraser (smfr) 2017-05-04 17:31:44 PDT
Comment on attachment 309117 [details]
Patch

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

> LayoutTests/fast/images/async-image-background-image-repeated.html:18
> +        background-image: url("");

Maybe just remove the property?

> LayoutTests/fast/images/async-image-background-image.html:9
> +        background-image: url("");

Remove?
Comment 8 Said Abou-Hallawa 2017-05-04 18:12:30 PDT
Created attachment 309122 [details]
Patch
Comment 9 WebKit Commit Bot 2017-05-04 18:53:34 PDT
Comment on attachment 309122 [details]
Patch

Clearing flags on attachment: 309122

Committed r216225: <http://trac.webkit.org/changeset/216225>
Comment 10 WebKit Commit Bot 2017-05-04 18:53:35 PDT
All reviewed patches have been landed.  Closing bug.