summaryrefslogtreecommitdiff
path: root/util.py
diff options
context:
space:
mode:
authorSam Thursfield <sam.thursfield@codethink.co.uk>2014-03-11 15:04:21 +0000
committerSam Thursfield <sam.thursfield@codethink.co.uk>2014-03-11 15:04:21 +0000
commit4fbdab363b301c24933601746766afa4b9c4435e (patch)
tree889edc86d0b9fb0c297d2e409ac9928c35d2a8b8 /util.py
parent6e75813a8938f7e27c5a9d779f0c1c325a556650 (diff)
downloadsystem-tests-4fbdab363b301c24933601746766afa4b9c4435e.tar.gz
A few fixes
Diffstat (limited to 'util.py')
-rw-r--r--util.py19
1 files changed, 17 insertions, 2 deletions
diff --git a/util.py b/util.py
index 15c9c72..390e04c 100644
--- a/util.py
+++ b/util.py
@@ -25,11 +25,26 @@ import config
def run_morph(args, **kwargs):
- '''Run Morph on the current machine.'''
+ '''Run Morph on the current machine.
+
+ This is not quite compatible with the run_morph() shell function inside
+ Morph's Yarn's because these tests require connectivity to an actual Trove
+ and an actual VM host and therefore it's quite a different setup to the
+ self-contained Morph test suite.
+
+ '''
morph_command = config.MORPH_COMMAND
if isinstance(morph_command, str):
- morph_command = morph_command.split(' ')
+ if ' ' in morph_command:
+ morph_command = morph_command.split(' ')
+ else:
+ morph_command = [morph_command]
+
+ if config.log_dir is not None:
+ morph_command += ['--log', os.path.join(config.log_dir, 'morph.log')]
+
cmd = morph_command + args
+
if config.VERBOSE:
print ' '.join(cmd)
if 'stdout' not in kwargs: