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

Side by Side Diff: content/browser/gpu/gpu_data_manager_impl_unittest.cc

Issue 14335017: content: Use base::MessageLoop. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 7 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 "base/command_line.h" 5 #include "base/command_line.h"
6 #include "base/message_loop.h" 6 #include "base/message_loop.h"
7 #include "base/run_loop.h" 7 #include "base/run_loop.h"
8 #include "base/time.h" 8 #include "base/time.h"
9 #include "content/browser/gpu/gpu_data_manager_impl.h" 9 #include "content/browser/gpu/gpu_data_manager_impl.h"
10 #include "content/public/browser/gpu_data_manager_observer.h" 10 #include "content/public/browser/gpu_data_manager_observer.h"
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 virtual void TearDown() { 92 virtual void TearDown() {
93 } 93 }
94 94
95 base::Time JustBeforeExpiration(GpuDataManagerImpl* manager); 95 base::Time JustBeforeExpiration(GpuDataManagerImpl* manager);
96 base::Time JustAfterExpiration(GpuDataManagerImpl* manager); 96 base::Time JustAfterExpiration(GpuDataManagerImpl* manager);
97 void TestBlockingDomainFrom3DAPIs( 97 void TestBlockingDomainFrom3DAPIs(
98 GpuDataManagerImpl::DomainGuilt guilt_level); 98 GpuDataManagerImpl::DomainGuilt guilt_level);
99 void TestUnblockingDomainFrom3DAPIs( 99 void TestUnblockingDomainFrom3DAPIs(
100 GpuDataManagerImpl::DomainGuilt guilt_level); 100 GpuDataManagerImpl::DomainGuilt guilt_level);
101 101
102 MessageLoop message_loop_; 102 base::MessageLoop message_loop_;
103 }; 103 };
104 104
105 // We use new method instead of GetInstance() method because we want 105 // We use new method instead of GetInstance() method because we want
106 // each test to be independent of each other. 106 // each test to be independent of each other.
107 107
108 TEST_F(GpuDataManagerImplTest, GpuSideBlacklisting) { 108 TEST_F(GpuDataManagerImplTest, GpuSideBlacklisting) {
109 // If a feature is allowed in preliminary step (browser side), but 109 // If a feature is allowed in preliminary step (browser side), but
110 // disabled when GPU process launches and collects full GPU info, 110 // disabled when GPU process launches and collects full GPU info,
111 // it's too late to let renderer know, so we basically block all GPU 111 // it's too late to let renderer know, so we basically block all GPU
112 // access, to be on the safe side. 112 // access, to be on the safe side.
(...skipping 486 matching lines...) Expand 10 before | Expand all | Expand 10 after
599 CommandLine command_line(0, NULL); 599 CommandLine command_line(0, NULL);
600 manager->AppendGpuCommandLine(&command_line); 600 manager->AppendGpuCommandLine(&command_line);
601 601
602 EXPECT_TRUE(command_line.HasSwitch(switches::kGpuDriverBugWorkarounds)); 602 EXPECT_TRUE(command_line.HasSwitch(switches::kGpuDriverBugWorkarounds));
603 std::string args = command_line.GetSwitchValueASCII( 603 std::string args = command_line.GetSwitchValueASCII(
604 switches::kGpuDriverBugWorkarounds); 604 switches::kGpuDriverBugWorkarounds);
605 EXPECT_STREQ("5,7", args.c_str()); 605 EXPECT_STREQ("5,7", args.c_str());
606 } 606 }
607 607
608 } // namespace content 608 } // namespace content
OLDNEW
« no previous file with comments | « content/browser/gpu/browser_gpu_channel_host_factory.h ('k') | content/browser/gpu/gpu_functional_browsertest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698