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

Side by Side Diff: gpu/command_buffer/common/id_allocator_test.cc

Issue 682743002: Standardize usage of virtual/override/final specifiers. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 years, 1 month 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 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 // This file has the unit tests for the IdAllocator class. 5 // This file has the unit tests for the IdAllocator class.
6 6
7 #include "gpu/command_buffer/common/id_allocator.h" 7 #include "gpu/command_buffer/common/id_allocator.h"
8 #include "testing/gtest/include/gtest/gtest.h" 8 #include "testing/gtest/include/gtest/gtest.h"
9 9
10 namespace gpu { 10 namespace gpu {
11 11
12 class IdAllocatorTest : public testing::Test { 12 class IdAllocatorTest : public testing::Test {
13 protected: 13 protected:
14 virtual void SetUp() {} 14 void SetUp() override {}
15 virtual void TearDown() {} 15 void TearDown() override {}
16 16
17 IdAllocator* id_allocator() { return &id_allocator_; } 17 IdAllocator* id_allocator() { return &id_allocator_; }
18 18
19 private: 19 private:
20 IdAllocator id_allocator_; 20 IdAllocator id_allocator_;
21 }; 21 };
22 22
23 // Checks basic functionality: AllocateID, FreeID, InUse. 23 // Checks basic functionality: AllocateID, FreeID, InUse.
24 TEST_F(IdAllocatorTest, TestBasic) { 24 TEST_F(IdAllocatorTest, TestBasic) {
25 IdAllocator *allocator = id_allocator(); 25 IdAllocator *allocator = id_allocator();
(...skipping 93 matching lines...) Expand 10 before | Expand all | Expand 10 after
119 allocator->FreeID(id1 + 1); 119 allocator->FreeID(id1 + 1);
120 120
121 ResourceId id2 = allocator->AllocateID(); 121 ResourceId id2 = allocator->AllocateID();
122 ResourceId id3 = allocator->AllocateID(); 122 ResourceId id3 = allocator->AllocateID();
123 EXPECT_NE(id2, id3); 123 EXPECT_NE(id2, id3);
124 EXPECT_NE(kInvalidResource, id2); 124 EXPECT_NE(kInvalidResource, id2);
125 EXPECT_NE(kInvalidResource, id3); 125 EXPECT_NE(kInvalidResource, id3);
126 } 126 }
127 127
128 } // namespace gpu 128 } // namespace gpu
OLDNEW
« no previous file with comments | « gpu/command_buffer/common/gles2_cmd_format_test.cc ('k') | gpu/command_buffer/service/async_pixel_transfer_manager_egl.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698