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

Side by Side Diff: base/trace_event/heap_profiler_allocation_register_unittest.cc

Issue 1466413002: Update gtest to 786564fa4a3c, switch to googlemock in gtest Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years 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 2015 The Chromium Authors. All rights reserved. 1 // Copyright 2015 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/trace_event/heap_profiler_allocation_register.h" 5 #include "base/trace_event/heap_profiler_allocation_register.h"
6 6
7 #include "base/process/process_metrics.h" 7 #include "base/process/process_metrics.h"
8 #include "base/trace_event/heap_profiler_allocation_context.h" 8 #include "base/trace_event/heap_profiler_allocation_context.h"
9 #include "testing/gtest/include/gtest/gtest.h" 9 #include "testing/gtest/googletest/include/gtest/gtest.h"
10 10
11 namespace base { 11 namespace base {
12 namespace trace_event { 12 namespace trace_event {
13 13
14 class AllocationRegisterTest : public testing::Test { 14 class AllocationRegisterTest : public testing::Test {
15 public: 15 public:
16 static const uint32_t kNumBuckets = AllocationRegister::kNumBuckets; 16 static const uint32_t kNumBuckets = AllocationRegister::kNumBuckets;
17 static const uint32_t kNumCells = AllocationRegister::kNumCells; 17 static const uint32_t kNumCells = AllocationRegister::kNumCells;
18 18
19 // Returns the number of cells that the |AllocationRegister| can store per 19 // Returns the number of cells that the |AllocationRegister| can store per
(...skipping 200 matching lines...) Expand 10 before | Expand all | Expand 10 after
220 const size_t cells_per_page = GetNumCellsPerPage(); 220 const size_t cells_per_page = GetNumCellsPerPage();
221 221
222 ASSERT_DEATH(for (size_t j = 0; j < cells_per_page; j++) { 222 ASSERT_DEATH(for (size_t j = 0; j < cells_per_page; j++) {
223 reg.Insert(reinterpret_cast<void*>(i + j), 0, ctx); 223 reg.Insert(reinterpret_cast<void*>(i + j), 0, ctx);
224 }, ""); 224 }, "");
225 } 225 }
226 #endif 226 #endif
227 227
228 } // namespace trace_event 228 } // namespace trace_event
229 } // namespace base 229 } // namespace base
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698