Kaydet (Commit) 1c7015ea authored tarafından Oliver Bolte's avatar Oliver Bolte

INTEGRATION: CWS qadev16 (1.2.46); FILE MERGED

2004/02/05 09:54:33 sw 1.2.46.1: #i24566#
üst f6621e99
...@@ -2,9 +2,9 @@ ...@@ -2,9 +2,9 @@
* *
* $RCSfile: Runner.java,v $ * $RCSfile: Runner.java,v $
* *
* $Revision: 1.2 $ * $Revision: 1.3 $
* *
* last change:$Date: 2003-05-27 12:03:50 $ * last change:$Date: 2004-03-19 14:29:42 $
* *
* The Contents of this file are made available subject to the terms of * The Contents of this file are made available subject to the terms of
* either of the following licenses * either of the following licenses
...@@ -62,11 +62,12 @@ ...@@ -62,11 +62,12 @@
package org.openoffice; package org.openoffice;
import lib.TestParameters; import lib.TestParameters;
import lib.DynamicClassLoader; import util.DynamicClassLoader;
import base.TestBase; import base.TestBase;
import helper.ClParser; import helper.ClParser;
import helper.CfgParser; import helper.CfgParser;
/** /**
* The main class, will call ClParser and CfgParser to <br> * The main class, will call ClParser and CfgParser to <br>
* fill the TestParameters.<br> * fill the TestParameters.<br>
...@@ -75,6 +76,7 @@ import helper.CfgParser; ...@@ -75,6 +76,7 @@ import helper.CfgParser;
public class Runner { public class Runner {
public static void main(String[] args) { public static void main(String[] args) {
DynamicClassLoader dcl = new DynamicClassLoader(); DynamicClassLoader dcl = new DynamicClassLoader();
// get a class for test parameters // get a class for test parameters
...@@ -94,7 +96,19 @@ public class Runner { ...@@ -94,7 +96,19 @@ public class Runner {
//parse the commandline arguments //parse the commandline arguments
cli.getCommandLineParameter(param,args); cli.getCommandLineParameter(param,args);
System.out.println("TestJob: "+param.get("TestJob")); Object tj = param.get("TestJob");
if (tj==null) {
System.out.println("==========================================================================");
System.out.println("No TestJob given, please make sure that you ");
System.out.println("a.) called the OOoRunner with the paramter -o <job> or -sce <scenarioFile>");
System.out.println("or");
System.out.println("b.) have an entry called TestJob in your used properties file");
System.out.println("==========================================================================");
System.exit(-1);
}
System.out.println("TestJob: "+tj);
TestBase toExecute = (TestBase) dcl.getInstance("base."+ TestBase toExecute = (TestBase) dcl.getInstance("base."+
(String)param.get("TestBase")); (String)param.get("TestBase"));
...@@ -105,7 +119,7 @@ public class Runner { ...@@ -105,7 +119,7 @@ public class Runner {
System.out.println("Job "+param.get("TestJob")+" failed"); System.out.println("Job "+param.get("TestJob")+" failed");
System.exit(-1); System.exit(-1);
} else { } else {
System.out.println("Job "+param.get("TestJob")+" successful executed"); System.out.println("Job "+param.get("TestJob")+" done");
System.exit(0); System.exit(0);
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment