diff options
Diffstat (limited to 'apps/load_and_launch_browsertest.cc')
-rw-r--r-- | apps/load_and_launch_browsertest.cc | 24 |
1 files changed, 14 insertions, 10 deletions
diff --git a/apps/load_and_launch_browsertest.cc b/apps/load_and_launch_browsertest.cc index 6624de9..9432420 100644 --- a/apps/load_and_launch_browsertest.cc +++ b/apps/load_and_launch_browsertest.cc @@ -13,6 +13,7 @@ #include "chrome/browser/extensions/extension_browsertest.h" #include "chrome/browser/profiles/profile_manager.h" #include "chrome/common/chrome_switches.h" +#include "content/public/common/content_switches.h" #include "content/public/test/test_launcher.h" #include "extensions/test/extension_test_message_listener.h" @@ -20,6 +21,15 @@ using extensions::PlatformAppBrowserTest; namespace apps { +namespace { + +const char* kSwitchesToCopy[] = { + switches::kUserDataDir, + switches::kNoSandbox, +}; + +} // namespace + // TODO(jackhou): Enable this test once it works on OSX. It currently does not // work for the same reason --app-id doesn't. See http://crbug.com/148465 #if defined(OS_MACOSX) @@ -36,11 +46,8 @@ IN_PROC_BROWSER_TEST_F(PlatformAppBrowserTest, const base::CommandLine& cmdline = *base::CommandLine::ForCurrentProcess(); base::CommandLine new_cmdline(cmdline.GetProgram()); - - const char* kSwitchNames[] = { - switches::kUserDataDir, - }; - new_cmdline.CopySwitchesFrom(cmdline, kSwitchNames, arraysize(kSwitchNames)); + new_cmdline.CopySwitchesFrom(cmdline, kSwitchesToCopy, + arraysize(kSwitchesToCopy)); base::FilePath app_path = test_data_dir_ .AppendASCII("platform_apps") @@ -73,11 +80,8 @@ IN_PROC_BROWSER_TEST_F(PlatformAppBrowserTest, const base::CommandLine& cmdline = *base::CommandLine::ForCurrentProcess(); base::CommandLine new_cmdline(cmdline.GetProgram()); - - const char* kSwitchNames[] = { - switches::kUserDataDir, - }; - new_cmdline.CopySwitchesFrom(cmdline, kSwitchNames, arraysize(kSwitchNames)); + new_cmdline.CopySwitchesFrom(cmdline, kSwitchesToCopy, + arraysize(kSwitchesToCopy)); base::FilePath app_path = test_data_dir_ .AppendASCII("platform_apps") |