OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 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/data_use_measurement/content/data_use_measurement.h" | 5 #include <components/data_use_measurement/core/data_use_measurement.h> |
6 | |
7 #include <string> | 6 #include <string> |
8 | 7 |
9 #include "base/memory/scoped_ptr.h" | 8 #include "base/memory/scoped_ptr.h" |
10 #include "base/test/histogram_tester.h" | 9 #include "base/test/histogram_tester.h" |
11 #include "content/public/browser/resource_request_info.h" | 10 //#include "content/public/browser/resource_request_info.h" |
12 #include "net/base/network_change_notifier.h" | 11 #include "net/base/network_change_notifier.h" |
13 #include "net/base/request_priority.h" | 12 #include "net/base/request_priority.h" |
14 #include "net/socket/socket_test_util.h" | 13 #include "net/socket/socket_test_util.h" |
15 #include "net/url_request/url_request.h" | 14 #include "net/url_request/url_request.h" |
16 #include "net/url_request/url_request_test_util.h" | 15 #include "net/url_request/url_request_test_util.h" |
17 #include "testing/gtest/include/gtest/gtest.h" | 16 #include "testing/gtest/include/gtest/gtest.h" |
18 #include "url/gurl.h" | 17 #include "url/gurl.h" |
19 | 18 |
20 #if defined(OS_ANDROID) | 19 #if defined(OS_ANDROID) |
21 #include "base/android/application_status_listener.h" | 20 #include "base/android/application_status_listener.h" |
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
142 // background and OS is Android. | 141 // background and OS is Android. |
143 TEST_F(DataUseMeasurementTest, ApplicationStateTest) { | 142 TEST_F(DataUseMeasurementTest, ApplicationStateTest) { |
144 data_use_measurement()->OnApplicationStateChangeForTesting( | 143 data_use_measurement()->OnApplicationStateChangeForTesting( |
145 base::android::APPLICATION_STATE_HAS_STOPPED_ACTIVITIES); | 144 base::android::APPLICATION_STATE_HAS_STOPPED_ACTIVITIES); |
146 TestForAServiceRequest("Background."); | 145 TestForAServiceRequest("Background."); |
147 TestForAUserRequest("Background."); | 146 TestForAUserRequest("Background."); |
148 } | 147 } |
149 #endif | 148 #endif |
150 | 149 |
151 } // namespace data_use_measurement | 150 } // namespace data_use_measurement |
OLD | NEW |