public function siteSshCase::testSshMultipleArgs

8.0.x siteSshTest.php public siteSshCase::testSshMultipleArgs()
6.x siteSshTest.php public siteSshCase::testSshMultipleArgs()
7.x siteSshTest.php public siteSshCase::testSshMultipleArgs()
5.x siteSshTest.php public siteSshCase::testSshMultipleArgs()
master siteSshTest.php public siteSshCase::testSshMultipleArgs()

Test drush ssh with multiple arguments (preferred form).

File

tests/siteSshTest.php, line 46

Class

siteSshCase

Code

public function testSshMultipleArgs() {
  $options = array(
    'simulate' => NULL,
  );
  $this->drush('ssh', array('ls', '/path1', '/path2'), $options, 'user@server/path/to/drupal#sitename', NULL, self::EXIT_SUCCESS, '2>&1');
  $output = $this->getOutput();
  $expected = sprintf('Calling proc_open(ssh -o PasswordAuthentication=no %s@%s \'ls /path1 /path2\');', self::escapeshellarg('user'), self::escapeshellarg('server'));
  $this->assertEquals($expected, $output);
}