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

Unified Diff: chrome/browser/extensions/platform_app_browsertest.cc

Issue 9195018: Disable modal JavaScript dialogs for platform apps. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix tests Created 8 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 side-by-side diff with in-line comments
Download patch
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..8644eb205d74d808cb7f6cbfcfc5440cf28fd881 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,13 @@ IN_PROC_BROWSER_TEST_F(PlatformAppBrowserTest, MAYBE_DisallowNavigation) {
UTF8ToWide(script), &result));
EXPECT_TRUE(result);
}
+
+// Disabled until shell windows are implemented for non-GTK, non-Views toolkits.
+#if defined(TOOLKIT_GTK) || defined(TOOLKIT_VIEWS)
+#define MAYBE_DisallowModalDialogs DisallowModalDialogs
+#else
+#define MAYBE_DisallowModalDialogs DISABLED_DisallowModalDialogs
+#endif
+IN_PROC_BROWSER_TEST_F(PlatformAppBrowserTest, MAYBE_DisallowModalDialogs) {
+ ASSERT_TRUE(RunPlatformAppTest("platform_apps/modal_dialogs")) << message_;
+}
« no previous file with comments | « chrome/browser/extensions/extension_host.cc ('k') | chrome/test/data/extensions/platform_apps/modal_dialogs/main.html » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698