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

Unified Diff: chrome/browser/ui/browser_browsertest.cc

Issue 2093963003: [ash-md] Uses 'Chrome - <title>' format for browser windows in overview (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: [ash-md] Uses 'Chrome - <title>' format for browser windows in overview (comment) Created 4 years, 6 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/browser/ui/browser.cc ('k') | chrome/browser/ui/cocoa/browser_window_cocoa.mm » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/browser/ui/browser_browsertest.cc
diff --git a/chrome/browser/ui/browser_browsertest.cc b/chrome/browser/ui/browser_browsertest.cc
index 1afb3c46eb6dbbc3ddd78c4f8cf636daa42c47c5..67f5e4bf15db69b72c2ccce525b5cbb32de35fd6 100644
--- a/chrome/browser/ui/browser_browsertest.cc
+++ b/chrome/browser/ui/browser_browsertest.cc
@@ -156,9 +156,8 @@ const base::FilePath::CharType kDocRoot[] =
// Given a page title, returns the expected window caption string.
base::string16 WindowCaptionFromPageTitle(const base::string16& page_title) {
-#if defined(OS_MACOSX) || defined(OS_CHROMEOS)
- // On Mac or ChromeOS, we don't want to suffix the page title with
- // the application name.
+#if defined(OS_MACOSX)
+ // On Mac, we don't want to suffix the page title with the application name.
if (page_title.empty())
return l10n_util::GetStringUTF16(IDS_BROWSER_WINDOW_MAC_TAB_UNTITLED);
return page_title;
@@ -377,7 +376,8 @@ IN_PROC_BROWSER_TEST_F(BrowserTest, NoTitle) {
base::FilePath(base::FilePath::kCurrentDirectory),
base::FilePath(kTitle1File)));
EXPECT_EQ(LocaleWindowCaptionFromPageTitle(ASCIIToUTF16("title1.html")),
- browser()->GetWindowTitleForCurrentTab());
+ browser()->GetWindowTitleForCurrentTab(
+ true /* include_app_name */));
base::string16 tab_title;
ASSERT_TRUE(ui_test_utils::GetCurrentTabTitle(browser(), &tab_title));
EXPECT_EQ(ASCIIToUTF16("title1.html"), tab_title);
@@ -436,7 +436,8 @@ IN_PROC_BROWSER_TEST_F(BrowserTest, Title) {
base::FilePath(kTitle2File)));
const base::string16 test_title(ASCIIToUTF16("Title Of Awesomeness"));
EXPECT_EQ(LocaleWindowCaptionFromPageTitle(test_title),
- browser()->GetWindowTitleForCurrentTab());
+ browser()->GetWindowTitleForCurrentTab(
+ true /* include_app_name */));
base::string16 tab_title;
ASSERT_TRUE(ui_test_utils::GetCurrentTabTitle(browser(), &tab_title));
EXPECT_EQ(test_title, tab_title);
« no previous file with comments | « chrome/browser/ui/browser.cc ('k') | chrome/browser/ui/cocoa/browser_window_cocoa.mm » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698