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

Unified Diff: gpu/command_buffer/service/feature_info_unittest.cc

Issue 1871613002: Compute GpuDriverBugWorkarounds only one time in the GPU process (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 4 years, 8 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: gpu/command_buffer/service/feature_info_unittest.cc
diff --git a/gpu/command_buffer/service/feature_info_unittest.cc b/gpu/command_buffer/service/feature_info_unittest.cc
index 62c3a2e0aecc8e0e7f73a7100f9cedf09edaa3c0..b631d0dd9b8cb482b9e26f9c129ed09b69a1cec3 100644
--- a/gpu/command_buffer/service/feature_info_unittest.cc
+++ b/gpu/command_buffer/service/feature_info_unittest.cc
@@ -77,7 +77,8 @@ class FeatureInfoTest
GpuServiceTest::SetUpWithGLVersion(version, extensions);
TestHelper::SetupFeatureInfoInitExpectationsWithGLVersion(
gl_.get(), extensions, renderer, version);
- info_ = new FeatureInfo();
+ gpu::GpuDriverBugWorkarounds::Initialize(gpu_driver_bug_workarounds_);
+ info_ = new FeatureInfo(gpu_driver_bug_workarounds_);
info_->InitializeForTesting();
}
@@ -89,7 +90,8 @@ class FeatureInfoTest
GpuServiceTest::SetUpWithGLVersion(version, extensions);
TestHelper::SetupFeatureInfoInitExpectationsWithGLVersion(
gl_.get(), extensions, renderer, version);
- info_ = new FeatureInfo();
+ gpu::GpuDriverBugWorkarounds::Initialize(gpu_driver_bug_workarounds_);
+ info_ = new FeatureInfo(gpu_driver_bug_workarounds_);
info_->InitializeForTesting(disallowed_features);
}
@@ -101,13 +103,17 @@ class FeatureInfoTest
GpuServiceTest::SetUpWithGLVersion(version, extensions);
TestHelper::SetupFeatureInfoInitExpectationsWithGLVersion(
gl_.get(), extensions, renderer, version);
- info_ = new FeatureInfo(command_line);
+ gpu::GpuDriverBugWorkarounds::Initialize(&command_line,
+ gpu_driver_bug_workarounds_);
+ info_ = new FeatureInfo(command_line, gpu_driver_bug_workarounds_);
info_->InitializeForTesting();
}
void SetupWithCommandLine(const base::CommandLine& command_line) {
GpuServiceTest::SetUp();
- info_ = new FeatureInfo(command_line);
+ gpu::GpuDriverBugWorkarounds::Initialize(&command_line,
+ gpu_driver_bug_workarounds_);
+ info_ = new FeatureInfo(command_line, gpu_driver_bug_workarounds_);
}
void SetupInitExpectationsWithCommandLine(
@@ -116,13 +122,16 @@ class FeatureInfoTest
GpuServiceTest::SetUpWithGLVersion("2.0", extensions);
TestHelper::SetupFeatureInfoInitExpectationsWithGLVersion(
gl_.get(), extensions, "", "");
- info_ = new FeatureInfo(command_line);
+ gpu::GpuDriverBugWorkarounds::Initialize(&command_line,
+ gpu_driver_bug_workarounds_);
+ info_ = new FeatureInfo(command_line, gpu_driver_bug_workarounds_);
info_->InitializeForTesting();
}
void SetupWithoutInit() {
GpuServiceTest::SetUp();
- info_ = new FeatureInfo();
+ gpu::GpuDriverBugWorkarounds::Initialize(gpu_driver_bug_workarounds_);
+ info_ = new FeatureInfo(gpu_driver_bug_workarounds_);
}
protected:

Powered by Google App Engine
This is Rietveld 408576698