|
|
@ -2,6 +2,7 @@
|
|
|
|
import os
|
|
|
|
import os
|
|
|
|
import shutil
|
|
|
|
import shutil
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
import timeoutcontext
|
|
|
|
import unittest2
|
|
|
|
import unittest2
|
|
|
|
|
|
|
|
|
|
|
|
import mitogen.fakessh
|
|
|
|
import mitogen.fakessh
|
|
|
@ -10,6 +11,7 @@ import testlib
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
class RsyncTest(testlib.DockerMixin, unittest2.TestCase):
|
|
|
|
class RsyncTest(testlib.DockerMixin, unittest2.TestCase):
|
|
|
|
|
|
|
|
@timeoutcontext.timeout(5)
|
|
|
|
def test_rsync_from_master(self):
|
|
|
|
def test_rsync_from_master(self):
|
|
|
|
context = self.docker_ssh_any()
|
|
|
|
context = self.docker_ssh_any()
|
|
|
|
|
|
|
|
|
|
|
@ -25,6 +27,7 @@ class RsyncTest(testlib.DockerMixin, unittest2.TestCase):
|
|
|
|
self.assertTrue(context.call(os.path.exists, '/tmp/data'))
|
|
|
|
self.assertTrue(context.call(os.path.exists, '/tmp/data'))
|
|
|
|
self.assertTrue(context.call(os.path.exists, '/tmp/data/simple_pkg/a.py'))
|
|
|
|
self.assertTrue(context.call(os.path.exists, '/tmp/data/simple_pkg/a.py'))
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
@timeoutcontext.timeout(5)
|
|
|
|
def test_rsync_between_direct_children(self):
|
|
|
|
def test_rsync_between_direct_children(self):
|
|
|
|
# master -> SSH -> has-sudo-pubkey -> rsync(.ssh) -> master ->
|
|
|
|
# master -> SSH -> has-sudo-pubkey -> rsync(.ssh) -> master ->
|
|
|
|
# has-sudo -> rsync
|
|
|
|
# has-sudo -> rsync
|
|
|
|