test_raw.py 661 B

1234567891011121314151617181920212223
  1. # -*- coding: utf-8 -*-
  2. from __future__ import absolute_import, print_function, unicode_literals
  3. import salt.utils.platform
  4. from tests.support.case import SSHCase
  5. from tests.support.helpers import slowTest
  6. from tests.support.unit import skipIf
  7. @skipIf(salt.utils.platform.is_windows(), "salt-ssh not available on Windows")
  8. class SSHRawTest(SSHCase):
  9. """
  10. testing salt-ssh with raw calls
  11. """
  12. @slowTest
  13. def test_ssh_raw(self):
  14. """
  15. test salt-ssh with -r argument
  16. """
  17. msg = "running raw msg"
  18. ret = self.run_function("echo {0}".format(msg), raw=True)
  19. self.assertEqual(ret["stdout"], msg + "\n")