Index: chrome/browser/extensions/platform_app_browsertest.cc |
diff --git a/chrome/browser/extensions/platform_app_browsertest.cc b/chrome/browser/extensions/platform_app_browsertest.cc |
index 515b177fd94f2019c2d57ca94f288ae63f727e3e..ed1177788bccbc675b011e71dc73928f2a4b7e46 100644 |
--- a/chrome/browser/extensions/platform_app_browsertest.cc |
+++ b/chrome/browser/extensions/platform_app_browsertest.cc |
@@ -5,6 +5,7 @@ |
#include "base/command_line.h" |
#include "base/stringprintf.h" |
#include "base/utf_string_conversions.h" |
+#include "chrome/browser/extensions/extension_apitest.h" |
#include "chrome/browser/extensions/extension_browsertest.h" |
#include "chrome/browser/extensions/extension_host.h" |
#include "chrome/browser/extensions/extension_service.h" |
@@ -44,7 +45,7 @@ class PlatformAppContextMenu : public RenderViewContextMenu { |
} // namespace |
-class PlatformAppBrowserTest : public ExtensionBrowserTest { |
+class PlatformAppBrowserTest : public ExtensionApiTest { |
public: |
virtual void SetUpCommandLine(CommandLine* command_line) { |
ExtensionBrowserTest::SetUpCommandLine(command_line); |
@@ -183,7 +184,7 @@ IN_PROC_BROWSER_TEST_F(PlatformAppBrowserTest, MAYBE_AppWithContextMenu) { |
#define MAYBE_DisallowNavigation DISABLED_DisallowNavigation |
#endif |
IN_PROC_BROWSER_TEST_F(PlatformAppBrowserTest, MAYBE_DisallowNavigation) { |
- ASSERT_TRUE(test_server()->Start()); |
+ ASSERT_TRUE(test_server()->Start()); |
LoadAndLaunchPlatformApp("navigation"); |
WebContents* web_contents = GetFirstPlatformAppWebContents(); |
@@ -199,3 +200,15 @@ IN_PROC_BROWSER_TEST_F(PlatformAppBrowserTest, MAYBE_DisallowNavigation) { |
UTF8ToWide(script), &result)); |
EXPECT_TRUE(result); |
} |
+ |
+ |
+// Tests that localStorage and WebSQL are disabled for platform apps. |
+// Disabled until shell windows are implemented for non-GTK, non-Views toolkits. |
+#if defined(TOOLKIT_GTK) || defined(TOOLKIT_VIEWS) |
+#define MAYBE_DisallowStorage DisallowStorage |
+#else |
+#define MAYBE_DisallowStorage DISABLED_DisallowStorage |
+#endif |
+IN_PROC_BROWSER_TEST_F(PlatformAppBrowserTest, MAYBE_DisallowStorage) { |
+ ASSERT_TRUE(RunExtensionTest("platform_apps/storage")) << message_; |
+} |