cloudstack-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From seb...@apache.org
Subject git commit: updated refs/heads/master to 16e4f2f
Date Fri, 21 Jun 2013 12:31:57 GMT
Updated Branches:
  refs/heads/master a401127b0 -> 16e4f2ff7


format deployAndRun


Project: http://git-wip-us.apache.org/repos/asf/cloudstack/repo
Commit: http://git-wip-us.apache.org/repos/asf/cloudstack/commit/16e4f2ff
Tree: http://git-wip-us.apache.org/repos/asf/cloudstack/tree/16e4f2ff
Diff: http://git-wip-us.apache.org/repos/asf/cloudstack/diff/16e4f2ff

Branch: refs/heads/master
Commit: 16e4f2ff7221bfbd4ac171aae4702e62f43574d3
Parents: a401127
Author: Daan Hoogland <dhoogland@schubergphilis.com>
Authored: Fri Jun 21 11:38:53 2013 +0200
Committer: Sebastien Goasguen <runseb@gmail.com>
Committed: Fri Jun 21 08:30:43 2013 -0400

----------------------------------------------------------------------
 tools/marvin/marvin/deployAndRun.py | 53 ++++++++++++++++++--------------
 1 file changed, 30 insertions(+), 23 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cloudstack/blob/16e4f2ff/tools/marvin/marvin/deployAndRun.py
----------------------------------------------------------------------
diff --git a/tools/marvin/marvin/deployAndRun.py b/tools/marvin/marvin/deployAndRun.py
index c83065a..78c1617 100644
--- a/tools/marvin/marvin/deployAndRun.py
+++ b/tools/marvin/marvin/deployAndRun.py
@@ -5,9 +5,9 @@
 # to you under the Apache License, Version 2.0 (the
 # "License"); you may not use this file except in compliance
 # with the License.  You may obtain a copy of the License at
-# 
+#
 #   http://www.apache.org/licenses/LICENSE-2.0
-# 
+#
 # Unless required by applicable law or agreed to in writing,
 # software distributed under the License is distributed on an
 # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
@@ -22,46 +22,53 @@ if __name__ == "__main__":
 
     parser = ArgumentParser()
 
-    parser.add_argument("-d", "--directory", dest="testCaseFolder", help="the test case directory")
-    parser.add_argument("-f", "--file", dest="module", help="run tests in the given file")
-    parser.add_argument("-r", "--result", dest="result", help="test result log file", default='/tmp/t.log')
-    parser.add_argument("-t", "--client", dest="testcaselog", help="test case log file",
default='/tmp/r.log')
-    parser.add_argument("-c", "--config", action="store", default="./datacenterCfg", dest="config",
-        help="the path where the json config file generated, by default is ./datacenterCfg")
+    parser.add_argument("-d", "--directory", dest="testCaseFolder",
+                        help="the test case directory")
+    parser.add_argument("-f", "--file", dest="module",
+                        help="run tests in the given file")
+    parser.add_argument("-r", "--result", dest="result",
+                        help="test result log file", default='/tmp/t.log')
+    parser.add_argument("-t", "--client", dest="testcaselog",
+                        help="test case log file", default='/tmp/r.log')
+    parser.add_argument("-c", "--config", action="store",
+                        default="./datacenterCfg", dest="config",
+                        help="the path where the json config file generated,\
+ by default is ./datacenterCfg")
     parser.add_argument("-l", "--load", dest="load", action="store_true",
-        help="only load config, do not deploy, it will only run testcase")
+                        help="only load config, do not deploy,\
+ it will only run testcase")
 
     options = parser.parse_args()
 
     testResultLogFile = None
     if options.result is not None:
         testResultLogFile = options.result
-    
+
     testCaseLogFile = None
     if options.testcaselog is not None:
         testCaseLogFile = options.testcaselog
-    deploy = deployDataCenter.deployDataCenters(options.config)    
+    deploy = deployDataCenter.deployDataCenters(options.config)
     if options.load:
         deploy.loadCfg()
     else:
         deploy.deploy()
-        
+
     if options.testCaseFolder is None:
         if options.module is None:
             parser.print_usage()
             exit(1)
         else:
-            engine =  \
-            TestCaseExecuteEngine.TestCaseExecuteEngine(deploy.testClient,
-                                                        deploy.getCfg(),
-                                                        testCaseLogFile,
-                                                        testResultLogFile)
-            engine.loadTestsFromFile(options.module)
-            engine.run()
-    else:
-       engine = TestCaseExecuteEngine.TestCaseExecuteEngine(deploy.testClient,
+            engine = \
+                TestCaseExecuteEngine.TestCaseExecuteEngine(deploy.testClient,
                                                             deploy.getCfg(),
                                                             testCaseLogFile,
                                                             testResultLogFile)
-       engine.loadTestsFromDir(options.testCaseFolder)
-       engine.run()
+            engine.loadTestsFromFile(options.module)
+            engine.run()
+    else:
+        engine = TestCaseExecuteEngine.TestCaseExecuteEngine(deploy.testClient,
+                                                             deploy.getCfg(),
+                                                             testCaseLogFile,
+                                                             testResultLogFile)
+        engine.loadTestsFromDir(options.testCaseFolder)
+        engine.run()


Mime
View raw message