| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/previews/previews_data_savings.h" | 5 #include "components/previews/core/previews_data_savings.h" |
| 6 | 6 |
| 7 #include <stdint.h> | 7 #include <stdint.h> |
| 8 | 8 |
| 9 #include <memory> | 9 #include <memory> |
| 10 #include <string> | 10 #include <string> |
| 11 | 11 |
| 12 #include "base/test/histogram_tester.h" | 12 #include "base/test/histogram_tester.h" |
| 13 #include "components/data_reduction_proxy/core/common/data_savings_recorder.h" | 13 #include "components/data_reduction_proxy/core/common/data_savings_recorder.h" |
| 14 #include "testing/gtest/include/gtest/gtest.h" | 14 #include "testing/gtest/include/gtest/gtest.h" |
| 15 | 15 |
| (...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 157 histogram_tester()->ExpectBucketCount( | 157 histogram_tester()->ExpectBucketCount( |
| 158 "Previews.ContentLength.DataSaverEnabled", twenty, 1); | 158 "Previews.ContentLength.DataSaverEnabled", twenty, 1); |
| 159 histogram_tester()->ExpectUniqueSample( | 159 histogram_tester()->ExpectUniqueSample( |
| 160 "Previews.DataInflation.DataSaverEnabled", twenty - ten, 1); | 160 "Previews.DataInflation.DataSaverEnabled", twenty - ten, 1); |
| 161 histogram_tester()->ExpectUniqueSample( | 161 histogram_tester()->ExpectUniqueSample( |
| 162 "Previews.DataInflationPercent.DataSaverEnabled", | 162 "Previews.DataInflationPercent.DataSaverEnabled", |
| 163 (twenty_kb - ten_kb) * 100 / twenty_kb, 1); | 163 (twenty_kb - ten_kb) * 100 / twenty_kb, 1); |
| 164 } | 164 } |
| 165 | 165 |
| 166 } // namespace previews | 166 } // namespace previews |
| OLD | NEW |