1 // Copyright (c) 2012 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_content_browser_client.h"
9 #include "base/files/file_path.h"
10 #include "base/logging.h"
11 #include "content/test/test_web_contents_view.h"
12 #include "googleurl/src/gurl.h"
16 TestContentBrowserClient::TestContentBrowserClient() {
19 TestContentBrowserClient::~TestContentBrowserClient() {
22 WebContentsViewPort
* TestContentBrowserClient::OverrideCreateWebContentsView(
23 WebContents
* web_contents
,
24 RenderViewHostDelegateView
** render_view_host_delegate_view
) {
28 TestWebContentsView
* rv
= new TestWebContentsView
;
29 *render_view_host_delegate_view
= rv
;
34 base::FilePath
TestContentBrowserClient::GetDefaultDownloadDirectory() {
35 if (!download_dir_
.IsValid()) {
36 bool result
= download_dir_
.CreateUniqueTempDir();
39 return download_dir_
.path();
42 } // namespace content