Index: chrome/test/webdriver/webdriver_automation.cc |
diff --git a/chrome/test/webdriver/webdriver_automation.cc b/chrome/test/webdriver/webdriver_automation.cc |
index f8ea88aedd25216c1692556515c440c82e123492..71b4dd9a57ccd5af94a3e9337cbde413b68db26f 100644 |
--- a/chrome/test/webdriver/webdriver_automation.cc |
+++ b/chrome/test/webdriver/webdriver_automation.cc |
@@ -202,6 +202,9 @@ void Automation::Init( |
Error** error) { |
// Prepare Chrome's command line. |
CommandLine command(CommandLine::NO_PROGRAM); |
+ if (CommandLine::ForCurrentProcess()->HasSwitch("no-sandbox")) { |
+ command.AppendSwitch(switches::kNoSandbox); |
+ } |
command.AppendSwitch(switches::kDisableHangMonitor); |
command.AppendSwitch(switches::kDisablePromptOnRepost); |
command.AppendSwitch(switches::kDomAutomationController); |