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

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

Issue 2819086: Removal of TabContentsDelegate::GetBrowser() interface method (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: '' Created 10 years, 4 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 | Annotate | Revision Log
« no previous file with comments | « chrome/test/browser_with_test_window_test.cc ('k') | no next file » | 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/in_process_browser_test.h" 5 #include "chrome/test/in_process_browser_test.h"
6 6
7 #include "base/command_line.h" 7 #include "base/command_line.h"
8 #include "base/file_path.h" 8 #include "base/file_path.h"
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/path_service.h" 10 #include "base/path_service.h"
(...skipping 233 matching lines...) Expand 10 before | Expand all | Expand 10 after
244 return http_server_.get(); 244 return http_server_.get();
245 } 245 }
246 246
247 // Creates a browser with a single tab (about:blank), waits for the tab to 247 // Creates a browser with a single tab (about:blank), waits for the tab to
248 // finish loading and shows the browser. 248 // finish loading and shows the browser.
249 Browser* InProcessBrowserTest::CreateBrowser(Profile* profile) { 249 Browser* InProcessBrowserTest::CreateBrowser(Profile* profile) {
250 Browser* browser = Browser::Create(profile); 250 Browser* browser = Browser::Create(profile);
251 251
252 browser->AddTabWithURL(GURL(chrome::kAboutBlankURL), GURL(), 252 browser->AddTabWithURL(GURL(chrome::kAboutBlankURL), GURL(),
253 PageTransition::START_PAGE, -1, 253 PageTransition::START_PAGE, -1,
254 TabStripModel::ADD_SELECTED, NULL, std::string()); 254 TabStripModel::ADD_SELECTED, NULL, std::string(),
255 &browser);
255 256
256 // Wait for the page to finish loading. 257 // Wait for the page to finish loading.
257 ui_test_utils::WaitForNavigation( 258 ui_test_utils::WaitForNavigation(
258 &browser->GetSelectedTabContents()->controller()); 259 &browser->GetSelectedTabContents()->controller());
259 260
260 browser->window()->Show(); 261 browser->window()->Show();
261 262
262 return browser; 263 return browser;
263 } 264 }
264 265
(...skipping 71 matching lines...) Expand 10 before | Expand all | Expand 10 after
336 337
337 GTEST_NONFATAL_FAILURE_(error_message.c_str()); 338 GTEST_NONFATAL_FAILURE_(error_message.c_str());
338 339
339 MessageLoopForUI::current()->Quit(); 340 MessageLoopForUI::current()->Quit();
340 } 341 }
341 342
342 void InProcessBrowserTest::SetInitialTimeoutInMS(int timeout_value) { 343 void InProcessBrowserTest::SetInitialTimeoutInMS(int timeout_value) {
343 DCHECK_GT(timeout_value, 0); 344 DCHECK_GT(timeout_value, 0);
344 initial_timeout_ = timeout_value; 345 initial_timeout_ = timeout_value;
345 } 346 }
OLDNEW
« no previous file with comments | « chrome/test/browser_with_test_window_test.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698