OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 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 "components/variations/entropy_provider.h" | 5 #include "components/variations/entropy_provider.h" |
6 | 6 |
7 #include <stddef.h> | 7 #include <stddef.h> |
8 #include <stdint.h> | 8 #include <stdint.h> |
9 | 9 |
10 #include <cmath> | 10 #include <cmath> |
11 #include <limits> | 11 #include <limits> |
12 #include <numeric> | 12 #include <numeric> |
13 | 13 |
14 #include "base/guid.h" | 14 #include "base/guid.h" |
15 #include "base/macros.h" | 15 #include "base/macros.h" |
16 #include "base/memory/scoped_ptr.h" | |
17 #include "base/rand_util.h" | 16 #include "base/rand_util.h" |
18 #include "base/strings/string_number_conversions.h" | 17 #include "base/strings/string_number_conversions.h" |
19 #include "components/variations/metrics_util.h" | 18 #include "components/variations/metrics_util.h" |
20 #include "testing/gtest/include/gtest/gtest.h" | 19 #include "testing/gtest/include/gtest/gtest.h" |
21 | 20 |
22 namespace metrics { | 21 namespace metrics { |
23 | 22 |
24 namespace { | 23 namespace { |
25 | 24 |
26 // Size of the low entropy source to use for the permuted entropy provider | 25 // Size of the low entropy source to use for the permuted entropy provider |
(...skipping 335 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
362 ++count; | 361 ++count; |
363 } | 362 } |
364 | 363 |
365 ASSERT_LT(count, kMaxAttempts) << "Expected average was " << | 364 ASSERT_LT(count, kMaxAttempts) << "Expected average was " << |
366 kExpectedAverage << ", average ended at " << cumulative_average << | 365 kExpectedAverage << ", average ended at " << cumulative_average << |
367 ", for trial " << kTestTrialNames[i]; | 366 ", for trial " << kTestTrialNames[i]; |
368 } | 367 } |
369 } | 368 } |
370 | 369 |
371 } // namespace metrics | 370 } // namespace metrics |
OLD | NEW |