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

Side by Side Diff: components/previews/core/previews_data_savings_unittest.cc

Issue 2333003002: Changed previews component to be a layered component. (Closed)
Patch Set: Rebased on master Created 4 years, 3 months 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 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
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
OLDNEW
« no previous file with comments | « components/previews/core/previews_data_savings.cc ('k') | components/previews/core/previews_experiments.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698