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

Side by Side Diff: chrome/browser/ui/browser_browsertest.cc

Issue 1260033003: Partially componentize //chrome/browser/search/search.{h,cc} (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Rebase Created 5 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
OLDNEW
1 // Copyright 2012 The Chromium Authors. All rights reserved. 1 // Copyright 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 <string> 5 #include <string>
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/compiler_specific.h" 9 #include "base/compiler_specific.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 583 matching lines...) Expand 10 before | Expand all | Expand 10 after
594 } 594 }
595 } 595 }
596 596
597 // Test that a browser-initiated navigation to an aborted URL load leaves around 597 // Test that a browser-initiated navigation to an aborted URL load leaves around
598 // a pending entry if we start from the NTP but not from a normal page. 598 // a pending entry if we start from the NTP but not from a normal page.
599 // See http://crbug.com/355537. 599 // See http://crbug.com/355537.
600 IN_PROC_BROWSER_TEST_F(BrowserTest, ClearPendingOnFailUnlessNTP) { 600 IN_PROC_BROWSER_TEST_F(BrowserTest, ClearPendingOnFailUnlessNTP) {
601 ASSERT_TRUE(test_server()->Start()); 601 ASSERT_TRUE(test_server()->Start());
602 WebContents* web_contents = 602 WebContents* web_contents =
603 browser()->tab_strip_model()->GetActiveWebContents(); 603 browser()->tab_strip_model()->GetActiveWebContents();
604 GURL ntp_url(chrome::GetNewTabPageURL(browser()->profile())); 604 GURL ntp_url(search::GetNewTabPageURL(browser()->profile()));
605 ui_test_utils::NavigateToURL(browser(), ntp_url); 605 ui_test_utils::NavigateToURL(browser(), ntp_url);
606 606
607 // Navigate to a 204 URL (aborts with no content) on the NTP and make sure it 607 // Navigate to a 204 URL (aborts with no content) on the NTP and make sure it
608 // sticks around so that the user can edit it. 608 // sticks around so that the user can edit it.
609 GURL abort_url(test_server()->GetURL("nocontent")); 609 GURL abort_url(test_server()->GetURL("nocontent"));
610 { 610 {
611 content::WindowedNotificationObserver stop_observer( 611 content::WindowedNotificationObserver stop_observer(
612 content::NOTIFICATION_LOAD_STOP, 612 content::NOTIFICATION_LOAD_STOP,
613 content::Source<NavigationController>( 613 content::Source<NavigationController>(
614 &web_contents->GetController())); 614 &web_contents->GetController()));
(...skipping 2383 matching lines...) Expand 10 before | Expand all | Expand 10 after
2998 // the observer (to make sure that the event fires twice and we don't 2998 // the observer (to make sure that the event fires twice and we don't
2999 // just see the previous event's style). 2999 // just see the previous event's style).
3000 observer.ClearLatestSecurityStyleAndExplanations(); 3000 observer.ClearLatestSecurityStyleAndExplanations();
3001 3001
3002 // Other conditions cannot be tested after clicking through because 3002 // Other conditions cannot be tested after clicking through because
3003 // once the interstitial is clicked through, all URLs for this host 3003 // once the interstitial is clicked through, all URLs for this host
3004 // will remain in a broken state. 3004 // will remain in a broken state.
3005 ProceedThroughInterstitial(web_contents); 3005 ProceedThroughInterstitial(web_contents);
3006 CheckExpiredSecurityStyle(observer); 3006 CheckExpiredSecurityStyle(observer);
3007 } 3007 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698