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

Side by Side Diff: chrome/browser/extensions/extension_install_ui_browsertest.cc

Issue 6209001: Change DCHECK in BookmarkBarGtk to DLOG and return. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: merge Created 9 years, 11 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 | « no previous file | chrome/browser/ui/gtk/bookmark_bar_gtk.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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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 "base/string_util.h" 5 #include "base/string_util.h"
6 #include "chrome/browser/extensions/extension_browsertest.h" 6 #include "chrome/browser/extensions/extension_browsertest.h"
7 #include "chrome/browser/extensions/extension_service.h" 7 #include "chrome/browser/extensions/extension_service.h"
8 #include "chrome/browser/extensions/theme_installed_infobar_delegate.h" 8 #include "chrome/browser/extensions/theme_installed_infobar_delegate.h"
9 #include "chrome/browser/profiles/profile.h" 9 #include "chrome/browser/profiles/profile.h"
10 #include "chrome/browser/tab_contents/tab_contents.h" 10 #include "chrome/browser/tab_contents/tab_contents.h"
(...skipping 16 matching lines...) Expand all
27 ASSERT_TRUE(tab_contents); 27 ASSERT_TRUE(tab_contents);
28 ASSERT_EQ(1, tab_contents->infobar_delegate_count()); 28 ASSERT_EQ(1, tab_contents->infobar_delegate_count());
29 ConfirmInfoBarDelegate* delegate = 29 ConfirmInfoBarDelegate* delegate =
30 tab_contents->GetInfoBarDelegateAt(0)->AsConfirmInfoBarDelegate(); 30 tab_contents->GetInfoBarDelegateAt(0)->AsConfirmInfoBarDelegate();
31 ASSERT_TRUE(delegate); 31 ASSERT_TRUE(delegate);
32 delegate->Cancel(); 32 delegate->Cancel();
33 ASSERT_EQ(0, tab_contents->infobar_delegate_count()); 33 ASSERT_EQ(0, tab_contents->infobar_delegate_count());
34 } 34 }
35 }; 35 };
36 36
37 // Crashy, http://crbug.com/44548.
38 IN_PROC_BROWSER_TEST_F(ExtensionInstallUIBrowserTest, 37 IN_PROC_BROWSER_TEST_F(ExtensionInstallUIBrowserTest,
39 DISABLED_TestThemeInstallUndoResetsToDefault) { 38 TestThemeInstallUndoResetsToDefault) {
40 // Install theme once and undo to verify we go back to default theme. 39 // Install theme once and undo to verify we go back to default theme.
41 FilePath theme_path = test_data_dir_.AppendASCII("theme.crx"); 40 FilePath theme_path = test_data_dir_.AppendASCII("theme.crx");
42 ASSERT_TRUE(InstallExtensionWithUI(theme_path, 1)); 41 ASSERT_TRUE(InstallExtensionWithUI(theme_path, 1));
43 const Extension* theme = browser()->profile()->GetTheme(); 42 const Extension* theme = browser()->profile()->GetTheme();
44 ASSERT_TRUE(theme); 43 ASSERT_TRUE(theme);
45 ASSERT_EQ(theme_crx, theme->id()); 44 ASSERT_EQ(theme_crx, theme->id());
46 VerifyThemeInfoBarAndUndoInstall(); 45 VerifyThemeInfoBarAndUndoInstall();
47 ASSERT_EQ(NULL, browser()->profile()->GetTheme()); 46 ASSERT_EQ(NULL, browser()->profile()->GetTheme());
48 47
49 // Set the same theme twice and undo to verify we go back to default theme. 48 // Set the same theme twice and undo to verify we go back to default theme.
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
92 incognito_profile)); 91 incognito_profile));
93 92
94 EXPECT_EQ(num_incognito_tabs, incognito_browser->tab_count()); 93 EXPECT_EQ(num_incognito_tabs, incognito_browser->tab_count());
95 EXPECT_EQ(num_normal_tabs + 1, browser()->tab_count()); 94 EXPECT_EQ(num_normal_tabs + 1, browser()->tab_count());
96 TabContents* tab_contents = browser()->GetSelectedTabContents(); 95 TabContents* tab_contents = browser()->GetSelectedTabContents();
97 ASSERT_TRUE(tab_contents); 96 ASSERT_TRUE(tab_contents);
98 EXPECT_TRUE(StartsWithASCII(tab_contents->GetURL().spec(), 97 EXPECT_TRUE(StartsWithASCII(tab_contents->GetURL().spec(),
99 "chrome://newtab/#app-id=", // id changes 98 "chrome://newtab/#app-id=", // id changes
100 false)); 99 false));
101 } 100 }
OLDNEW
« no previous file with comments | « no previous file | chrome/browser/ui/gtk/bookmark_bar_gtk.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698