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

Unified Diff: cc/test/layer_tree_test.cc

Issue 508373002: cc: Single-threaded impl-side painting for unit tests (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Swap promise unit test Created 6 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: cc/test/layer_tree_test.cc
diff --git a/cc/test/layer_tree_test.cc b/cc/test/layer_tree_test.cc
index 9b9bae634abc92183976d9dd33f21bec6bbd0b94..2c95269335b1f49d6b849122eed698191f14fdd0 100644
--- a/cc/test/layer_tree_test.cc
+++ b/cc/test/layer_tree_test.cc
@@ -200,6 +200,9 @@ class LayerTreeHostImplForTesting : public LayerTreeHostImpl {
}
virtual void BlockNotifyReadyToActivateForTesting(bool block) override {
+ CHECK(settings().impl_side_painting);
+ CHECK(proxy()->ImplThreadTaskRunner())
+ << "Not supported for single-threaded mode.";
block_notify_ready_to_activate_for_testing_ = block;
if (!block && notify_ready_to_activate_was_blocked_) {
NotifyReadyToActivate();
@@ -636,11 +639,7 @@ void LayerTreeTest::RunTest(bool threaded,
// Spend less time waiting for BeginFrame because the output is
// mocked out.
settings_.refresh_rate = 200.0;
- if (impl_side_painting) {
- DCHECK(threaded)
- << "Don't run single thread + impl side painting, it doesn't exist.";
- settings_.impl_side_painting = true;
- }
+ settings_.impl_side_painting = impl_side_painting;
InitializeSettings(&settings_);
main_task_runner_->PostTask(

Powered by Google App Engine
This is Rietveld 408576698