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

Side by Side Diff: cc/test/layer_tree_test.cc

Issue 888663003: cc: Fix flakiness in LayerTreeHostCopyRequestTestMultipleDrawsHiddenCopyRequest (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 10 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 unified diff | Download patch
« no previous file with comments | « cc/test/layer_tree_test.h ('k') | cc/trees/layer_tree_host_unittest_copyrequest.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2011 The Chromium Authors. All rights reserved. 1 // Copyright 2011 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "cc/test/layer_tree_test.h" 5 #include "cc/test/layer_tree_test.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "cc/animation/animation.h" 8 #include "cc/animation/animation.h"
9 #include "cc/animation/animation_registrar.h" 9 #include "cc/animation/animation_registrar.h"
10 #include "cc/animation/layer_animation_controller.h" 10 #include "cc/animation/layer_animation_controller.h"
(...skipping 555 matching lines...) Expand 10 before | Expand all | Expand 10 after
566 main_thread_weak_ptr_)); 566 main_thread_weak_ptr_));
567 } 567 }
568 568
569 void LayerTreeTest::PostCompositeImmediatelyToMainThread() { 569 void LayerTreeTest::PostCompositeImmediatelyToMainThread() {
570 main_task_runner_->PostTask( 570 main_task_runner_->PostTask(
571 FROM_HERE, 571 FROM_HERE,
572 base::Bind(&LayerTreeTest::DispatchCompositeImmediately, 572 base::Bind(&LayerTreeTest::DispatchCompositeImmediately,
573 main_thread_weak_ptr_)); 573 main_thread_weak_ptr_));
574 } 574 }
575 575
576 void LayerTreeTest::PostEndTestToMainThread() {
577 main_task_runner_->PostTask(
578 FROM_HERE, base::Bind(&LayerTreeTest::EndTest, main_thread_weak_ptr_));
579 }
580
581 void LayerTreeTest::WillBeginTest() { 576 void LayerTreeTest::WillBeginTest() {
582 layer_tree_host_->SetLayerTreeHostClientReady(); 577 layer_tree_host_->SetLayerTreeHostClientReady();
583 } 578 }
584 579
585 void LayerTreeTest::DoBeginTest() { 580 void LayerTreeTest::DoBeginTest() {
586 client_ = LayerTreeHostClientForTesting::Create(this); 581 client_ = LayerTreeHostClientForTesting::Create(this);
587 582
588 scoped_ptr<FakeExternalBeginFrameSource> external_begin_frame_source; 583 scoped_ptr<FakeExternalBeginFrameSource> external_begin_frame_source;
589 if (settings_.use_external_begin_frame_source) { 584 if (settings_.use_external_begin_frame_source) {
590 external_begin_frame_source.reset(new FakeExternalBeginFrameSource( 585 external_begin_frame_source.reset(new FakeExternalBeginFrameSource(
(...skipping 205 matching lines...) Expand 10 before | Expand all | Expand 10 after
796 return -1; 791 return -1;
797 } 792 }
798 793
799 void LayerTreeTest::DestroyLayerTreeHost() { 794 void LayerTreeTest::DestroyLayerTreeHost() {
800 if (layer_tree_host_ && layer_tree_host_->root_layer()) 795 if (layer_tree_host_ && layer_tree_host_->root_layer())
801 layer_tree_host_->root_layer()->SetLayerTreeHost(NULL); 796 layer_tree_host_->root_layer()->SetLayerTreeHost(NULL);
802 layer_tree_host_ = nullptr; 797 layer_tree_host_ = nullptr;
803 } 798 }
804 799
805 } // namespace cc 800 } // namespace cc
OLDNEW
« no previous file with comments | « cc/test/layer_tree_test.h ('k') | cc/trees/layer_tree_host_unittest_copyrequest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698