Index: base/metrics/sample_map_unittest.cc |
diff --git a/base/metrics/sample_map_unittest.cc b/base/metrics/sample_map_unittest.cc |
index 22ce8e1c8e3ab3a347af2e008ce622bb662cd67d..c941d65f061af1dab3050613b2a136cab9bdd55e 100644 |
--- a/base/metrics/sample_map_unittest.cc |
+++ b/base/metrics/sample_map_unittest.cc |
@@ -11,7 +11,7 @@ namespace base { |
namespace { |
TEST(SampleMapTest, AccumulateTest) { |
- SampleMap samples; |
+ SampleMap samples(1); |
samples.Accumulate(1, 100); |
samples.Accumulate(2, 200); |
@@ -25,8 +25,8 @@ TEST(SampleMapTest, AccumulateTest) { |
} |
TEST(SampleMapTest, AddSubtractTest) { |
- SampleMap samples1; |
- SampleMap samples2; |
+ SampleMap samples1(1); |
+ SampleMap samples2(2); |
samples1.Accumulate(1, 100); |
samples1.Accumulate(2, 100); |
@@ -56,7 +56,7 @@ TEST(SampleMapTest, AddSubtractTest) { |
} |
TEST(SampleMapIteratorTest, IterateTest) { |
- SampleMap samples; |
+ SampleMap samples(1); |
samples.Accumulate(1, 100); |
samples.Accumulate(2, 200); |
samples.Accumulate(4, -300); |
@@ -91,14 +91,14 @@ TEST(SampleMapIteratorTest, IterateTest) { |
} |
TEST(SampleMapIteratorTest, SkipEmptyRanges) { |
- SampleMap samples; |
+ SampleMap samples(1); |
samples.Accumulate(5, 1); |
samples.Accumulate(10, 2); |
samples.Accumulate(15, 3); |
samples.Accumulate(20, 4); |
samples.Accumulate(25, 5); |
- SampleMap samples2; |
+ SampleMap samples2(2); |
samples2.Accumulate(5, 1); |
samples2.Accumulate(20, 4); |
samples2.Accumulate(25, 5); |
@@ -132,7 +132,7 @@ TEST(SampleMapIteratorTest, SkipEmptyRanges) { |
#if (!defined(NDEBUG) || defined(DCHECK_ALWAYS_ON)) && GTEST_HAS_DEATH_TEST |
TEST(SampleMapIteratorDeathTest, IterateDoneTest) { |
- SampleMap samples; |
+ SampleMap samples(1); |
scoped_ptr<SampleCountIterator> it = samples.Iterator(); |