remote_access: enforce shell=True on shell commands

Using shell strings instead of argv commands is fragile and error prone
and we've long discouraged it for local RunCommands.  Update the remote
API with the same shell=True check and convert most existing shell users
over to the argv form.

BUG=None
TEST=precq passes

Change-Id: Ic2d598f33aa0f04bc73350717d1e130d1b58fa1a
Reviewed-on: https://chromium-review.googlesource.com/697065
Commit-Ready: Mike Frysinger <vapier@chromium.org>
Tested-by: Mike Frysinger <vapier@chromium.org>
Reviewed-by: Dan Erat <derat@chromium.org>
diff --git a/scripts/deploy_chrome_unittest.py b/scripts/deploy_chrome_unittest.py
index 872ed8e..c7c6731 100644
--- a/scripts/deploy_chrome_unittest.py
+++ b/scripts/deploy_chrome_unittest.py
@@ -103,8 +103,7 @@
     self.rsh_mock = remote_access_unittest.RemoteShMock()
     self.rsh_mock.SetDefaultCmdResult(0)
     self.MockMountCmd(1)
-    self.rsh_mock.AddCmdResult(
-        deploy_chrome.LSOF_COMMAND % (deploy_chrome._CHROME_DIR,), 1)
+    self.rsh_mock.AddCmdResult(['lsof', deploy_chrome._CHROME_DIR], 1)
 
   def MockMountCmd(self, returnvalue):
     self.rsh_mock.AddCmdResult(deploy_chrome.MOUNT_RW_COMMAND,
@@ -201,7 +200,7 @@
   """Test detection of a running 'ui' job."""
 
   def MockStatusUiCmd(self, **kwargs):
-    self.deploy_mock.rsh_mock.AddCmdResult('status ui', **kwargs)
+    self.deploy_mock.rsh_mock.AddCmdResult(['status', 'ui'], **kwargs)
 
   def testUiJobStartedFalse(self):
     """Correct results with a stopped job."""