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

Side by Side Diff: content/test/test_navigation_url_loader_delegate.h

Issue 1917053003: unique_ptr_migration: clean up references to scoped_ptr as of r389721 (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: . Created 4 years, 7 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 #ifndef CONTENT_TEST_TEST_NAVIGATION_URL_LOADER_DELEGATE_H_ 5 #ifndef CONTENT_TEST_TEST_NAVIGATION_URL_LOADER_DELEGATE_H_
6 #define CONTENT_TEST_TEST_NAVIGATION_URL_LOADER_DELEGATE_H_ 6 #define CONTENT_TEST_TEST_NAVIGATION_URL_LOADER_DELEGATE_H_
7 7
8 #include <memory>
9
8 #include "base/macros.h" 10 #include "base/macros.h"
9 #include "base/memory/ref_counted.h" 11 #include "base/memory/ref_counted.h"
10 #include "base/memory/scoped_ptr.h"
11 #include "base/time/time.h" 12 #include "base/time/time.h"
12 #include "content/browser/loader/navigation_url_loader_delegate.h" 13 #include "content/browser/loader/navigation_url_loader_delegate.h"
13 #include "net/url_request/redirect_info.h" 14 #include "net/url_request/redirect_info.h"
14 15
15 namespace base { 16 namespace base {
16 class RunLoop; 17 class RunLoop;
17 } 18 }
18 19
19 namespace content { 20 namespace content {
20 21
(...skipping 26 matching lines...) Expand all
47 void WaitForRequestFailed(); 48 void WaitForRequestFailed();
48 void WaitForRequestStarted(); 49 void WaitForRequestStarted();
49 50
50 void ReleaseBody(); 51 void ReleaseBody();
51 52
52 // NavigationURLLoaderDelegate implementation. 53 // NavigationURLLoaderDelegate implementation.
53 void OnRequestRedirected( 54 void OnRequestRedirected(
54 const net::RedirectInfo& redirect_info, 55 const net::RedirectInfo& redirect_info,
55 const scoped_refptr<ResourceResponse>& response) override; 56 const scoped_refptr<ResourceResponse>& response) override;
56 void OnResponseStarted(const scoped_refptr<ResourceResponse>& response, 57 void OnResponseStarted(const scoped_refptr<ResourceResponse>& response,
57 scoped_ptr<StreamHandle> body) override; 58 std::unique_ptr<StreamHandle> body) override;
58 void OnRequestFailed(bool in_cache, int net_error) override; 59 void OnRequestFailed(bool in_cache, int net_error) override;
59 void OnRequestStarted(base::TimeTicks timestamp) override; 60 void OnRequestStarted(base::TimeTicks timestamp) override;
60 61
61 private: 62 private:
62 net::RedirectInfo redirect_info_; 63 net::RedirectInfo redirect_info_;
63 scoped_refptr<ResourceResponse> redirect_response_; 64 scoped_refptr<ResourceResponse> redirect_response_;
64 scoped_refptr<ResourceResponse> response_; 65 scoped_refptr<ResourceResponse> response_;
65 scoped_ptr<StreamHandle> body_; 66 std::unique_ptr<StreamHandle> body_;
66 int net_error_; 67 int net_error_;
67 int on_request_handled_counter_; 68 int on_request_handled_counter_;
68 69
69 scoped_ptr<base::RunLoop> request_redirected_; 70 std::unique_ptr<base::RunLoop> request_redirected_;
70 scoped_ptr<base::RunLoop> response_started_; 71 std::unique_ptr<base::RunLoop> response_started_;
71 scoped_ptr<base::RunLoop> request_failed_; 72 std::unique_ptr<base::RunLoop> request_failed_;
72 scoped_ptr<base::RunLoop> request_started_; 73 std::unique_ptr<base::RunLoop> request_started_;
73 74
74 DISALLOW_COPY_AND_ASSIGN(TestNavigationURLLoaderDelegate); 75 DISALLOW_COPY_AND_ASSIGN(TestNavigationURLLoaderDelegate);
75 }; 76 };
76 77
77 } // namespace content 78 } // namespace content
78 79
79 #endif // CONTENT_TEST_TEST_NAVIGATION_URL_LOADER_DELEGATE_H 80 #endif // CONTENT_TEST_TEST_NAVIGATION_URL_LOADER_DELEGATE_H
OLDNEW
« no previous file with comments | « content/renderer/mus/compositor_mus_connection_unittest.cc ('k') | content/test/test_navigation_url_loader_delegate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698