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/domain_reliability/uploader.h" | 5 #include "components/domain_reliability/uploader.h" |
6 | 6 |
| 7 #include <stddef.h> |
| 8 |
7 #include "base/bind.h" | 9 #include "base/bind.h" |
8 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
9 #include "base/message_loop/message_loop.h" | 11 #include "base/message_loop/message_loop.h" |
10 #include "base/run_loop.h" | 12 #include "base/run_loop.h" |
11 #include "base/test/test_simple_task_runner.h" | 13 #include "base/test/test_simple_task_runner.h" |
12 #include "components/domain_reliability/test_util.h" | 14 #include "components/domain_reliability/test_util.h" |
13 #include "net/base/load_flags.h" | 15 #include "net/base/load_flags.h" |
14 #include "net/http/http_response_headers.h" | 16 #include "net/http/http_response_headers.h" |
15 #include "net/http/http_response_info.h" | 17 #include "net/http/http_response_info.h" |
16 #include "net/url_request/url_request.h" | 18 #include "net/url_request/url_request.h" |
(...skipping 251 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
268 TestUploadCallback c; | 270 TestUploadCallback c; |
269 uploader()->UploadReport("{}", 1, GURL(kUploadURL), c.callback()); | 271 uploader()->UploadReport("{}", 1, GURL(kUploadURL), c.callback()); |
270 base::RunLoop().RunUntilIdle(); | 272 base::RunLoop().RunUntilIdle(); |
271 EXPECT_EQ(1u, c.called_count()); | 273 EXPECT_EQ(1u, c.called_count()); |
272 | 274 |
273 EXPECT_EQ(2, interceptor()->last_upload_depth()); | 275 EXPECT_EQ(2, interceptor()->last_upload_depth()); |
274 } | 276 } |
275 | 277 |
276 } // namespace | 278 } // namespace |
277 } // namespace domain_reliability | 279 } // namespace domain_reliability |
OLD | NEW |