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

Side by Side Diff: chrome/test/base/in_process_browser_test.cc

Issue 9372065: Update clients to use new TestServer constructor. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Remove files that were reviewed and committed separately. Created 8 years, 10 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
« no previous file with comments | « chrome/test/automation/automation_proxy_uitest.cc ('k') | chrome/test/perf/mach_ports_test.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 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 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 "chrome/test/base/in_process_browser_test.h" 5 #include "chrome/test/base/in_process_browser_test.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/debug/stack_trace.h" 9 #include "base/debug/stack_trace.h"
10 #include "base/file_path.h" 10 #include "base/file_path.h"
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after
65 // be run instead of a renderer). 65 // be run instead of a renderer).
66 FilePath chrome_path; 66 FilePath chrome_path;
67 CHECK(PathService::Get(base::FILE_EXE, &chrome_path)); 67 CHECK(PathService::Get(base::FILE_EXE, &chrome_path));
68 chrome_path = chrome_path.DirName(); 68 chrome_path = chrome_path.DirName();
69 chrome_path = chrome_path.Append(chrome::kBrowserProcessExecutablePath); 69 chrome_path = chrome_path.Append(chrome::kBrowserProcessExecutablePath);
70 CHECK(PathService::Override(base::FILE_EXE, chrome_path)); 70 CHECK(PathService::Override(base::FILE_EXE, chrome_path));
71 #endif // defined(OS_MACOSX) 71 #endif // defined(OS_MACOSX)
72 72
73 test_server_.reset(new net::TestServer( 73 test_server_.reset(new net::TestServer(
74 net::TestServer::TYPE_HTTP, 74 net::TestServer::TYPE_HTTP,
75 net::TestServer::kLocalhost,
75 FilePath(FILE_PATH_LITERAL("chrome/test/data")))); 76 FilePath(FILE_PATH_LITERAL("chrome/test/data"))));
76 } 77 }
77 78
78 InProcessBrowserTest::~InProcessBrowserTest() { 79 InProcessBrowserTest::~InProcessBrowserTest() {
79 } 80 }
80 81
81 void InProcessBrowserTest::SetUp() { 82 void InProcessBrowserTest::SetUp() {
82 // Create a temporary user data directory if required. 83 // Create a temporary user data directory if required.
83 ASSERT_TRUE(CreateUserDataDirectory()) 84 ASSERT_TRUE(CreateUserDataDirectory())
84 << "Could not create user data directory."; 85 << "Could not create user data directory.";
(...skipping 240 matching lines...) Expand 10 before | Expand all | Expand 10 after
325 if (BrowserList::size() == 0) 326 if (BrowserList::size() == 0)
326 return; 327 return;
327 328
328 // Invoke CloseAllBrowsersAndMayExit on a running message loop. 329 // Invoke CloseAllBrowsersAndMayExit on a running message loop.
329 // CloseAllBrowsersAndMayExit exits the message loop after everything has been 330 // CloseAllBrowsersAndMayExit exits the message loop after everything has been
330 // shut down properly. 331 // shut down properly.
331 MessageLoopForUI::current()->PostTask(FROM_HERE, 332 MessageLoopForUI::current()->PostTask(FROM_HERE,
332 base::Bind(&BrowserList::AttemptExit)); 333 base::Bind(&BrowserList::AttemptExit));
333 ui_test_utils::RunMessageLoop(); 334 ui_test_utils::RunMessageLoop();
334 } 335 }
OLDNEW
« no previous file with comments | « chrome/test/automation/automation_proxy_uitest.cc ('k') | chrome/test/perf/mach_ports_test.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698