1 // Copyright (c) 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
5 #include "content/test/test_navigation_url_loader.h"
7 #include "content/browser/loader/navigation_url_loader_delegate.h"
8 #include "content/public/browser/stream_handle.h"
12 TestNavigationURLLoader::TestNavigationURLLoader(
13 const CommonNavigationParams
& common_params
,
14 scoped_ptr
<NavigationRequestInfo
> request_info
,
15 NavigationURLLoaderDelegate
* delegate
)
16 : common_params_(common_params
),
17 request_info_(request_info
.Pass()),
22 void TestNavigationURLLoader::FollowRedirect() {
26 void TestNavigationURLLoader::CallOnRequestRedirected(
27 const net::RedirectInfo
& redirect_info
,
28 const scoped_refptr
<ResourceResponse
>& response
) {
29 delegate_
->OnRequestRedirected(redirect_info
, response
);
32 void TestNavigationURLLoader::CallOnResponseStarted(
33 const scoped_refptr
<ResourceResponse
>& response
,
34 scoped_ptr
<StreamHandle
> body
) {
35 delegate_
->OnResponseStarted(response
, body
.Pass());
38 TestNavigationURLLoader::~TestNavigationURLLoader() {}
40 } // namespace content