Author: liuzhe Date: Fri Oct 26 09:03:28 2012 New Revision: 1402437 URL: http://svn.apache.org/viewvc?rev=1402437&view=rev Log: Update usage for Run
Added: incubator/ooo/trunk/test/testcommon/source/org/openoffice/test/Run.help Modified: incubator/ooo/trunk/test/testcommon/source/org/openoffice/test/Run.java Added: incubator/ooo/trunk/test/testcommon/source/org/openoffice/test/Run.help URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/test/testcommon/source/org/openoffice/test/Run.help?rev=1402437&view=auto ============================================================================== --- incubator/ooo/trunk/test/testcommon/source/org/openoffice/test/Run.help (added) +++ incubator/ooo/trunk/test/testcommon/source/org/openoffice/test/Run.help Fri Oct 26 09:03:28 2012 @@ -0,0 +1,23 @@ +Usage: +run [options] <test definition> [test definition] ... +Options + -D<property>=<value> Set system property. + -propertyfile <file> Set system property from property file. + -r Set a runnable which will be executed before all tests start. + -l Set a test listeners. + -help Print usage. +Test Definition + -tp [suite name:]<package name>[,package_name]... Define a test suite with test packages separated by comma. + -tc [suite name:]<class name>[,class_name]... Define a test suite with test classes separated by comma. + -tm [suite name:]<method name>[,method_name]... Define a test suite with test methods separated by comma. +System Property + openoffice.home Specify the directory in which OpenOffice is installed. + openoffice.pack Specify a URL to OpenOffice installation package. The package will be automatically installed. + singleton True to allow only one test process to run at a time. + only.new True to allow test to run only when openoffice.pack is newer than the local cached package. + report.to Specify a URL to upload test result. +Example + run -Dopenoffice.home=/Applications/OpenOffice.org.app/Contents -tp bvt + run -Dopenoffice.home=/Applications/OpenOffice.org.app/Contents -tc bvt:bvt.gui.BasicFunctionTest,bvt.gui.FileTypeTest + run -Dopenoffice.pack=http://ci.apache.org/projects/openoffice/install/linux64/Apache_OpenOffice_3.5.0_Linux_x86-64_install-arc_en-US.tar.gz -tp bvt + \ No newline at end of file Modified: incubator/ooo/trunk/test/testcommon/source/org/openoffice/test/Run.java URL: http://svn.apache.org/viewvc/incubator/ooo/trunk/test/testcommon/source/org/openoffice/test/Run.java?rev=1402437&r1=1402436&r2=1402437&view=diff ============================================================================== --- incubator/ooo/trunk/test/testcommon/source/org/openoffice/test/Run.java (original) +++ incubator/ooo/trunk/test/testcommon/source/org/openoffice/test/Run.java Fri Oct 26 09:03:28 2012 @@ -48,17 +48,7 @@ public class Run { private static void printUsage(String msg, int code) { if (msg != null) System.out.println(msg); - System.out.println("Usage: [options]"); - System.out.println(" -D<property>=<value> Set system property"); - System.out.println(" -propertyfile file Set system property from property file"); - System.out.println(" -r Set a runnable which will be executed before all tests start."); - System.out.println(" -l Set a test listeners."); - System.out.println(" -tp Define a test suite with test packages separated by comma. Format: [name]:org.package1,org.package2..."); - System.out.println(" -tc Define a test suite with test classes separated by comma. Format: [name]:org.package.Class1,org.package.Class2..."); - System.out.println(" -tm Define a test suite with test methods separated by comma. Format: [name]:org.package.Class1.method1,org.package.Class2.method1..."); - System.out.println("Example:"); - System.out.println("-tp mytest:com.test"); - System.out.println("-tc mytest:com.test.TestName1,com.test.TestName2"); + System.out.print(FileUtil.readStreamAsString(Run.class.getResourceAsStream("Run.help"), "utf-8")); System.exit(code); }