| Index: components/rappor/rappor_metric_unittest.cc
|
| diff --git a/components/rappor/rappor_metric_unittest.cc b/components/rappor/rappor_metric_unittest.cc
|
| index b5707cf3aa7f0f0464d6f6631a638784a2deed22..25b0432a6326df2a67b8bd008113693dd826d9ed 100644
|
| --- a/components/rappor/rappor_metric_unittest.cc
|
| +++ b/components/rappor/rappor_metric_unittest.cc
|
| @@ -49,10 +49,12 @@ TEST(RapporMetricTest, GetReport) {
|
| TEST(RapporMetricTest, GetReportStatistics) {
|
| RapporMetric metric("MyStatsRappor", kTestStatsRapporParameters, 0);
|
|
|
| - for (char i = 0; i < 50; i++) {
|
| - metric.AddSample(base::StringPrintf("%d", i));
|
| + ByteVector real_bits(kTestStatsRapporParameters.bloom_filter_size_bytes);
|
| + // Set 152 bits (19 bytes)
|
| + for (char i = 0; i < 19; i++) {
|
| + real_bits[i] = 0xff;
|
| }
|
| - const ByteVector real_bits = metric.bytes();
|
| + metric.SetBytesForTesting(real_bits);
|
| const int real_bit_count = CountBits(real_bits);
|
| EXPECT_EQ(real_bit_count, 152);
|
|
|
|
|