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

Side by Side Diff: gpu/config/gpu_driver_bug_list_unittest.cc

Issue 2424733002: Add unittest to avoid duplicate id in gpu driver bug list (Closed)
Patch Set: Created 4 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 unified diff | Download patch
OLDNEW
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 <stdint.h> 5 #include <stdint.h>
6 6
7 #include <memory> 7 #include <memory>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/logging.h" 10 #include "base/logging.h"
(...skipping 189 matching lines...) Expand 10 before | Expand all | Expand 10 after
200 200
201 bugs = list->MakeDecision(GpuControlList::kOsWin, "7.0", gpu_info); 201 bugs = list->MakeDecision(GpuControlList::kOsWin, "7.0", gpu_info);
202 EXPECT_EQ(1u, bugs.count(DISABLE_D3D11)); 202 EXPECT_EQ(1u, bugs.count(DISABLE_D3D11));
203 203
204 // test a higher driver version number 204 // test a higher driver version number
205 gpu_info.driver_version = "9.18.13.2723"; 205 gpu_info.driver_version = "9.18.13.2723";
206 bugs = list->MakeDecision(GpuControlList::kOsWin, "7.0", gpu_info); 206 bugs = list->MakeDecision(GpuControlList::kOsWin, "7.0", gpu_info);
207 EXPECT_EQ(0u, bugs.count(DISABLE_D3D11)); 207 EXPECT_EQ(0u, bugs.count(DISABLE_D3D11));
208 } 208 }
209 209
210 TEST_F(GpuDriverBugListTest, DuplicateBugIDCheck) {
Zhenyao Mo 2016/10/17 17:30:04 nit: Duplicate -> Duplicated.
qiankun 2016/10/18 01:52:56 Done.
211 std::unique_ptr<GpuDriverBugList> list(GpuDriverBugList::Create());
212 EXPECT_TRUE(list->LoadList(kGpuDriverBugListJson, GpuControlList::kAllOs));
213 EXPECT_FALSE(list->has_duplicate_entry_id());
214 }
215
210 } // namespace gpu 216 } // namespace gpu
211 217
OLDNEW
« gpu/config/gpu_control_list.h ('K') | « gpu/config/gpu_control_list.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698