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

Side by Side Diff: chrome/browser/sessions/better_session_restore_browsertest.cc

Issue 2935053002: Disable NoSessionRestoreTest.LocalStorageClearedOnExit on Windows (Closed)
Patch Set: Created 3 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 unified diff | Download patch
« no previous file with comments | « no previous file | 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) 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 <stddef.h> 5 #include <stddef.h>
6 6
7 #include <string> 7 #include <string>
8 8
9 #include "base/command_line.h" 9 #include "base/command_line.h"
10 #include "base/files/file_path.h" 10 #include "base/files/file_path.h"
(...skipping 723 matching lines...) Expand 10 before | Expand all | Expand 10 after
734 // Normally localStorage is persisted. 734 // Normally localStorage is persisted.
735 content::WebContents* web_contents = 735 content::WebContents* web_contents =
736 browser()->tab_strip_model()->GetActiveWebContents(); 736 browser()->tab_strip_model()->GetActiveWebContents();
737 EXPECT_EQ(std::string(url::kAboutBlankURL), web_contents->GetURL().spec()); 737 EXPECT_EQ(std::string(url::kAboutBlankURL), web_contents->GetURL().spec());
738 NavigateAndCheckStoredData("local_storage.html"); 738 NavigateAndCheckStoredData("local_storage.html");
739 // ... but not if it's set to clear on exit. 739 // ... but not if it's set to clear on exit.
740 CookieSettingsFactory::GetForProfile(browser()->profile()) 740 CookieSettingsFactory::GetForProfile(browser()->profile())
741 ->SetDefaultCookieSetting(CONTENT_SETTING_SESSION_ONLY); 741 ->SetDefaultCookieSetting(CONTENT_SETTING_SESSION_ONLY);
742 } 742 }
743 743
744 IN_PROC_BROWSER_TEST_F(NoSessionRestoreTest, LocalStorageClearedOnExit) { 744 // Crashes on Windows. http://crbug.com/732013
745 #if defined(OS_WIN)
746 #define MAYBE_NSRT_LocalStorageClearedOnExit DISABLED_LocalStorageClearedOnExit
747 #else
748 #define MAYBE_NSRT_LocalStorageClearedOnExit LocalStorageClearedOnExit
749 #endif
750 IN_PROC_BROWSER_TEST_F(NoSessionRestoreTest,
751 MAYBE_NSRT_LocalStorageClearedOnExit) {
745 content::WebContents* web_contents = 752 content::WebContents* web_contents =
746 browser()->tab_strip_model()->GetActiveWebContents(); 753 browser()->tab_strip_model()->GetActiveWebContents();
747 EXPECT_EQ(std::string(url::kAboutBlankURL), web_contents->GetURL().spec()); 754 EXPECT_EQ(std::string(url::kAboutBlankURL), web_contents->GetURL().spec());
748 StoreDataWithPage("local_storage.html"); 755 StoreDataWithPage("local_storage.html");
749 } 756 }
750 757
751 IN_PROC_BROWSER_TEST_F(NoSessionRestoreTest, PRE_PRE_CookiesClearedOnExit) { 758 IN_PROC_BROWSER_TEST_F(NoSessionRestoreTest, PRE_PRE_CookiesClearedOnExit) {
752 StoreDataWithPage("cookies.html"); 759 StoreDataWithPage("cookies.html");
753 } 760 }
754 761
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after
856 CookieSettingsFactory::GetForProfile(new_browser->profile()) 863 CookieSettingsFactory::GetForProfile(new_browser->profile())
857 ->SetDefaultCookieSetting(CONTENT_SETTING_SESSION_ONLY); 864 ->SetDefaultCookieSetting(CONTENT_SETTING_SESSION_ONLY);
858 // ... even if background mode is active. 865 // ... even if background mode is active.
859 EnableBackgroundMode(); 866 EnableBackgroundMode();
860 new_browser = QuitBrowserAndRestore(new_browser, true); 867 new_browser = QuitBrowserAndRestore(new_browser, true);
861 StoreDataWithPage(new_browser, "cookies.html"); 868 StoreDataWithPage(new_browser, "cookies.html");
862 DisableBackgroundMode(); 869 DisableBackgroundMode();
863 new_browser = QuitBrowserAndRestore(new_browser, true); 870 new_browser = QuitBrowserAndRestore(new_browser, true);
864 StoreDataWithPage(new_browser, "cookies.html"); 871 StoreDataWithPage(new_browser, "cookies.html");
865 } 872 }
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698