OLD | NEW |
1 // Copyright (c) 2013 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2013 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/memory/scoped_ptr.h" | 5 #include "base/memory/scoped_ptr.h" |
6 #include "gpu/config/gpu_blacklist.h" | 6 #include "gpu/config/gpu_blacklist.h" |
7 #include "gpu/config/gpu_control_list_jsons.h" | 7 #include "gpu/config/gpu_control_list_jsons.h" |
8 #include "gpu/config/gpu_feature_type.h" | 8 #include "gpu/config/gpu_feature_type.h" |
9 #include "gpu/config/gpu_info.h" | 9 #include "gpu/config/gpu_info.h" |
10 #include "testing/gtest/include/gtest/gtest.h" | 10 #include "testing/gtest/include/gtest/gtest.h" |
11 | 11 |
12 const char kOsVersion[] = "10.6.4"; | 12 const char kOsVersion[] = "10.6.4"; |
13 | 13 |
14 namespace gpu { | 14 namespace gpu { |
15 | 15 |
16 class GpuBlacklistTest : public testing::Test { | 16 class GpuBlacklistTest : public testing::Test { |
17 public: | 17 public: |
18 GpuBlacklistTest() { } | 18 GpuBlacklistTest() { } |
19 | 19 |
20 ~GpuBlacklistTest() override {} | 20 ~GpuBlacklistTest() override {} |
21 | 21 |
22 const GPUInfo& gpu_info() const { | 22 const GPUInfo& gpu_info() const { |
23 return gpu_info_; | 23 return gpu_info_; |
24 } | 24 } |
25 | 25 |
26 void RunFeatureTest( | 26 void RunFeatureTest(const std::string& feature_name, |
27 const std::string feature_name, GpuFeatureType feature_type) { | 27 GpuFeatureType feature_type) { |
28 const std::string json = | 28 const std::string json = |
29 "{\n" | 29 "{\n" |
30 " \"name\": \"gpu blacklist\",\n" | 30 " \"name\": \"gpu blacklist\",\n" |
31 " \"version\": \"0.1\",\n" | 31 " \"version\": \"0.1\",\n" |
32 " \"entries\": [\n" | 32 " \"entries\": [\n" |
33 " {\n" | 33 " {\n" |
34 " \"id\": 1,\n" | 34 " \"id\": 1,\n" |
35 " \"os\": {\n" | 35 " \"os\": {\n" |
36 " \"type\": \"macosx\"\n" | 36 " \"type\": \"macosx\"\n" |
37 " },\n" | 37 " },\n" |
(...skipping 80 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
118 | 118 |
119 GPU_BLACKLIST_FEATURE_TEST(PanelFitting, | 119 GPU_BLACKLIST_FEATURE_TEST(PanelFitting, |
120 "panel_fitting", | 120 "panel_fitting", |
121 GPU_FEATURE_TYPE_PANEL_FITTING) | 121 GPU_FEATURE_TYPE_PANEL_FITTING) |
122 | 122 |
123 GPU_BLACKLIST_FEATURE_TEST(GpuRasterization, | 123 GPU_BLACKLIST_FEATURE_TEST(GpuRasterization, |
124 "gpu_rasterization", | 124 "gpu_rasterization", |
125 GPU_FEATURE_TYPE_GPU_RASTERIZATION) | 125 GPU_FEATURE_TYPE_GPU_RASTERIZATION) |
126 | 126 |
127 } // namespace gpu | 127 } // namespace gpu |
OLD | NEW |