| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 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 #ifndef COMPONENTS_DOMAIN_RELIABILITY_TEST_UTIL_H_ | 5 #ifndef COMPONENTS_DOMAIN_RELIABILITY_TEST_UTIL_H_ |
| 6 #define COMPONENTS_DOMAIN_RELIABILITY_TEST_UTIL_H_ | 6 #define COMPONENTS_DOMAIN_RELIABILITY_TEST_UTIL_H_ |
| 7 | 7 |
| 8 #include "base/callback.h" | 8 #include "base/callback.h" |
| 9 #include "base/memory/scoped_ptr.h" |
| 10 #include "components/domain_reliability/config.h" |
| 9 #include "components/domain_reliability/monitor.h" | 11 #include "components/domain_reliability/monitor.h" |
| 12 #include "components/domain_reliability/scheduler.h" |
| 10 #include "components/domain_reliability/uploader.h" | 13 #include "components/domain_reliability/uploader.h" |
| 11 #include "components/domain_reliability/util.h" | 14 #include "components/domain_reliability/util.h" |
| 12 #include "net/base/host_port_pair.h" | 15 #include "net/base/host_port_pair.h" |
| 13 | 16 |
| 14 namespace net { | 17 namespace net { |
| 15 class URLRequestStatus; | 18 class URLRequestStatus; |
| 16 } // namespace net | 19 } // namespace net |
| 17 | 20 |
| 18 namespace domain_reliability { | 21 namespace domain_reliability { |
| 19 | 22 |
| (...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 105 | 108 |
| 106 int elapsed_sec() { return (now_ticks_ - epoch_ticks_).InSeconds(); } | 109 int elapsed_sec() { return (now_ticks_ - epoch_ticks_).InSeconds(); } |
| 107 | 110 |
| 108 base::Time now_; | 111 base::Time now_; |
| 109 base::TimeTicks now_ticks_; | 112 base::TimeTicks now_ticks_; |
| 110 base::TimeTicks epoch_ticks_; | 113 base::TimeTicks epoch_ticks_; |
| 111 int task_sequence_number_; | 114 int task_sequence_number_; |
| 112 TaskMap tasks_; | 115 TaskMap tasks_; |
| 113 }; | 116 }; |
| 114 | 117 |
| 118 scoped_ptr<const DomainReliabilityConfig> MakeTestConfig(); |
| 119 DomainReliabilityScheduler::Params MakeTestSchedulerParams(); |
| 120 |
| 115 } // namespace domain_reliability | 121 } // namespace domain_reliability |
| 116 | 122 |
| 117 #endif // COMPONENTS_DOMAIN_RELIABILITY_TEST_UTIL_H_ | 123 #endif // COMPONENTS_DOMAIN_RELIABILITY_TEST_UTIL_H_ |
| OLD | NEW |