| OLD | NEW |
| 1 // Copyright 2017 The Chromium Authors. All rights reserved. | 1 // Copyright 2017 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 "net/reporting/reporting_service.h" | 5 #include "net/reporting/reporting_service.h" |
| 6 | 6 |
| 7 #include <memory> | 7 #include <memory> |
| 8 #include <string> | 8 #include <string> |
| 9 | 9 |
| 10 #include "base/memory/ptr_util.h" | 10 #include "base/memory/ptr_util.h" |
| 11 #include "base/time/tick_clock.h" | 11 #include "base/time/tick_clock.h" |
| 12 #include "base/values.h" | 12 #include "base/values.h" |
| 13 #include "net/reporting/reporting_cache.h" | 13 #include "net/reporting/reporting_cache.h" |
| 14 #include "net/reporting/reporting_context.h" | 14 #include "net/reporting/reporting_context.h" |
| 15 #include "net/reporting/reporting_delegate.h" | |
| 16 #include "net/reporting/reporting_policy.h" | 15 #include "net/reporting/reporting_policy.h" |
| 17 #include "net/reporting/reporting_report.h" | 16 #include "net/reporting/reporting_report.h" |
| 18 #include "net/reporting/reporting_service.h" | 17 #include "net/reporting/reporting_service.h" |
| 19 #include "net/reporting/reporting_test_util.h" | 18 #include "net/reporting/reporting_test_util.h" |
| 20 #include "testing/gtest/include/gtest/gtest.h" | 19 #include "testing/gtest/include/gtest/gtest.h" |
| 21 | 20 |
| 22 namespace net { | 21 namespace net { |
| 23 namespace { | 22 namespace { |
| 24 | 23 |
| 25 class ReportingServiceTest : public ::testing::Test { | 24 class ReportingServiceTest : public ::testing::Test { |
| (...skipping 43 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 69 EXPECT_EQ(kOrigin_, client->origin); | 68 EXPECT_EQ(kOrigin_, client->origin); |
| 70 EXPECT_EQ(kEndpoint_, client->endpoint); | 69 EXPECT_EQ(kEndpoint_, client->endpoint); |
| 71 EXPECT_EQ(ReportingClient::Subdomains::EXCLUDE, client->subdomains); | 70 EXPECT_EQ(ReportingClient::Subdomains::EXCLUDE, client->subdomains); |
| 72 EXPECT_EQ(kGroup_, client->group); | 71 EXPECT_EQ(kGroup_, client->group); |
| 73 EXPECT_EQ(context()->tick_clock()->NowTicks() + base::TimeDelta::FromDays(1), | 72 EXPECT_EQ(context()->tick_clock()->NowTicks() + base::TimeDelta::FromDays(1), |
| 74 client->expires); | 73 client->expires); |
| 75 } | 74 } |
| 76 | 75 |
| 77 } // namespace | 76 } // namespace |
| 78 } // namespace net | 77 } // namespace net |
| OLD | NEW |