Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(216)

Issue 797063002: Make reftests work for sky. (Closed)

Created:
6 years ago by ojan
Modified:
6 years ago
Reviewers:
esprehn
CC:
esprehn, Aaron Boodman, abarth-chromium, ben+mojo_chromium.org, darin (slow to review), mojo-reviews_chromium.org, qsr+mojo_chromium.org, viettrungluu+watch_chromium.org, yzshen+watch_chromium.org
Base URL:
git@github.com:domokit/mojo.git@master
Target Ref:
refs/heads/master
Project:
mojo
Visibility:
Public.

Description

Make reftests work for sky. -Add a --testing flag to sky_viewer and cause it to paint into an SkBitmap instead of a ganesh surface so we can get the pixels out. -Add GetPixelsForTesting to layer.cc to actually grab out the pixels. -Add a reftest and a mismatch reftest. They need a setTimeout after the load event. Unclear why or what the right fix is. Maybe we should give internals some way to force the paint? If we don't have the setTimeout, we paint a white page (so we do a paint, but with no content). -Add a DisplayDelegate to Layer so that Viewer can decide whether to use the real ganesh backend or the SkBitmap one without littering the whole code-base with is_testing bools and logic. R=esprehn@chromium.org Committed: https://chromium.googlesource.com/external/mojo/+/9e174d2084be1ffeb32952b9ac91009f8af6e1a7

Patch Set 1 #

Total comments: 3

Patch Set 2 : cleanup #

Total comments: 6

Patch Set 3 : gets undefined symbol error when trying to run #

Patch Set 4 : address review comments #

Total comments: 6

Patch Set 5 : address review comments #

Unified diffs Side-by-side diffs Delta from patch set Stats (+364 lines, -30 lines) Patch
M examples/sky_compositor_app/sky_compositor_app.cc View 1 2 3 2 chunks +4 lines, -0 lines 0 comments Download
M sky/compositor/BUILD.gn View 1 2 1 chunk +6 lines, -0 lines 0 comments Download
A sky/compositor/display_delegate.h View 1 2 3 1 chunk +43 lines, -0 lines 0 comments Download
A sky/compositor/display_delegate.cc View 1 2 1 chunk +24 lines, -0 lines 0 comments Download
A sky/compositor/display_delegate_bitmap.h View 1 2 3 4 1 chunk +33 lines, -0 lines 0 comments Download
A sky/compositor/display_delegate_bitmap.cc View 1 2 3 1 chunk +39 lines, -0 lines 0 comments Download
A sky/compositor/display_delegate_ganesh.h View 1 2 3 4 1 chunk +31 lines, -0 lines 0 comments Download
A sky/compositor/display_delegate_ganesh.cc View 1 2 3 1 chunk +27 lines, -0 lines 0 comments Download
M sky/compositor/layer.h View 1 2 3 2 chunks +4 lines, -3 lines 0 comments Download
M sky/compositor/layer.cc View 1 2 3 2 chunks +10 lines, -9 lines 0 comments Download
M sky/compositor/layer_host.h View 1 2 3 1 chunk +2 lines, -0 lines 0 comments Download
M sky/compositor/layer_host.cc View 1 2 3 1 chunk +4 lines, -0 lines 0 comments Download
M sky/services/testing/test_harness.mojom View 1 2 3 1 chunk +1 line, -1 line 0 comments Download
A sky/tests/harness/reftest.sky View 1 2 3 4 1 chunk +12 lines, -0 lines 0 comments Download
A sky/tests/harness/reftest-expected.sky View 1 2 3 4 1 chunk +12 lines, -0 lines 0 comments Download
A sky/tests/harness/reftest-mismatch.sky View 1 2 3 4 1 chunk +12 lines, -0 lines 0 comments Download
A sky/tests/harness/reftest-mismatch-expected-mismatch.sky View 1 2 3 4 1 chunk +12 lines, -0 lines 0 comments Download
M sky/tools/tester/test_harness_impl.h View 1 2 3 1 chunk +2 lines, -1 line 0 comments Download
M sky/tools/tester/test_harness_impl.cc View 1 2 3 1 chunk +3 lines, -2 lines 0 comments Download
M sky/tools/tester/test_runner.h View 1 2 3 2 chunks +4 lines, -2 lines 0 comments Download
M sky/tools/tester/test_runner.cc View 1 2 3 2 chunks +16 lines, -3 lines 0 comments Download
M sky/tools/tester/tester.cc View 1 2 3 2 chunks +35 lines, -5 lines 0 comments Download
M sky/tools/webkitpy/layout_tests/port/base.py View 1 chunk +1 line, -0 lines 0 comments Download
M sky/viewer/document_view.h View 1 2 3 2 chunks +3 lines, -1 line 0 comments Download
M sky/viewer/document_view.cc View 1 2 3 2 chunks +6 lines, -2 lines 0 comments Download
M sky/viewer/internals.cc View 1 2 3 2 chunks +5 lines, -1 line 0 comments Download
M sky/viewer/viewer.cc View 1 2 3 3 chunks +13 lines, -0 lines 0 comments Download

Messages

Total messages: 7 (1 generated)
esprehn
Instead you might want a display delegate, and have Layer do something like DisplayDelegate::GetCurrent() and ...
6 years ago (2014-12-11 23:18:59 UTC) #2
ojan
Uploaded a new patch. It doesn't quite work yet. It compiles, but gets an undefined ...
6 years ago (2014-12-12 03:48:39 UTC) #3
ojan
weird...those comments are from earlier....i guess i forgot to send them before. in either case, ...
6 years ago (2014-12-12 03:49:57 UTC) #4
ojan
OK. This is ready for review. https://codereview.chromium.org/797063002/diff/20001/sky/compositor/layer.cc File sky/compositor/layer.cc (right): https://codereview.chromium.org/797063002/diff/20001/sky/compositor/layer.cc#newcode33 sky/compositor/layer.cc:33: std::string Layer::GetPixelsForTesting() { ...
6 years ago (2014-12-13 00:18:33 UTC) #5
esprehn
lgtm https://codereview.chromium.org/797063002/diff/60001/sky/compositor/display_delegate_bitmap.h File sky/compositor/display_delegate_bitmap.h (right): https://codereview.chromium.org/797063002/diff/60001/sky/compositor/display_delegate_bitmap.h#newcode14 sky/compositor/display_delegate_bitmap.h:14: class DisplayDelegateBitmap : public DisplayDelegate { final https://codereview.chromium.org/797063002/diff/60001/sky/compositor/display_delegate_bitmap.h#newcode16 ...
6 years ago (2014-12-13 00:24:42 UTC) #6
ojan
6 years ago (2014-12-13 00:45:53 UTC) #7
Message was sent while issue was closed.
Committed patchset #5 (id:80001) manually as
9e174d2084be1ffeb32952b9ac91009f8af6e1a7 (presubmit successful).

Powered by Google App Engine
This is Rietveld 408576698