Write results to stdout when result log is not specified

This commit is contained in:
Prasanna Santhanam 2012-09-11 10:02:32 +05:30 committed by Prasanna Santhanam
parent 653cdb3c5d
commit c4f91b2914

View File

@ -16,6 +16,7 @@
# under the License.
import marvin
import sys
import logging
import nose.core
from marvin.cloudstackTestCase import cloudstackTestCase
@ -52,7 +53,7 @@ class MarvinPlugin(Plugin):
self.logger.addHandler(ch)
self.result_stream = open(options.result_log, "w")
else:
self.result_stream = sys.stderr
self.result_stream = sys.stdout
deploy = deployDataCenter.deployDataCenters(options.config)
deploy.loadCfg() if options.load else deploy.deploy()
@ -73,7 +74,7 @@ class MarvinPlugin(Plugin):
dest="config",
help="Marvin's configuration file where the datacenter information is specified [MARVIN_CONFIG]")
parser.add_option("--result-log", action="store",
default=env.get('RESULT_LOG', 'result.log'),
default=env.get('RESULT_LOG', None),
dest="result_log",
help="The path to the results file where test summary will be written to [RESULT_LOG]")
parser.add_option("--client-log", action="store",