Add testsuite shortcut to make remote repository testing more robust.

This commit is contained in:
Jonas Borgström 2013-07-03 22:30:04 +02:00
parent 8bdda86ab4
commit f3295cf3e8
2 changed files with 5 additions and 2 deletions

View file

@ -80,7 +80,10 @@ class RemoteRepository(object):
self.unpacker = msgpack.Unpacker(use_list=False)
self.msgid = 0
self.received_msgid = 0
args = ['ssh', '-p', str(location.port), '%s@%s' % (location.user or getpass.getuser(), location.host), 'darc', 'serve']
if location.host == '__testsuite__':
args = [sys.executable, '-m', 'darc.archiver', 'serve']
else:
args = ['ssh', '-p', str(location.port), '%s@%s' % (location.user or getpass.getuser(), location.host), 'darc', 'serve']
self.p = Popen(args, bufsize=0, stdin=PIPE, stdout=PIPE)
self.stdin_fd = self.p.stdin.fileno()
self.stdout_fd = self.p.stdout.fileno()

View file

@ -219,4 +219,4 @@ class ArchiverTestCase(DarcTestCase):
class RemoteArchiverTestCase(ArchiverTestCase):
prefix = 'localhost:'
prefix = '__testsuite__:'