Commits

tundish committed 86992d2

Added XSpec test for extended ssh options

  • Participants
  • Parent commits 65593e9

Comments (0)

Files changed (1)

File testing/test_xspec.py

         spec = XSpec("popen")
         assert spec.popen == True
 
+    def test_ssh_options(self):
+        spec = XSpec("ssh=-p 22100 user@host//python=python3")
+        assert spec.ssh == "-p 22100 user@host"
+        assert spec.python == "python3"
+
+        spec = XSpec("ssh=-i ~/.ssh/id_rsa-passwordless_login -p 22100 user@host//python=python3")
+        assert spec.ssh == "-i ~/.ssh/id_rsa-passwordless_login -p 22100 user@host"
+        assert spec.python == "python3"
+
     def test_env(self):
         xspec = XSpec("popen//env:NAME=value1")
         assert xspec.env['NAME'] == "value1"