Merge commit 'codehaus'
[groovy.git] / src / test / UberTestCaseGroovySourceRootPackage.java
blob204e468da2fefe61d0f6e684bb460ed53ca6e7ad
1 /**
2 * Collects all TestCases in the Groovy test root that are written in Groovy.
4 * @author <a href="mailto:jeremy.rayner@bigfoot.com">Jeremy Rayner</a>
5 * @author Dierk Koenig (refactored to use AllTestSuite)
6 * @version $Revision$
7 */
9 import groovy.util.AllTestSuite;
10 import junit.framework.Test;
11 import junit.framework.TestCase;
12 import junit.framework.TestSuite;
14 public class UberTestCaseGroovySourceRootPackage extends TestCase {
15 public static Test suite() throws ClassNotFoundException {
16 TestSuite suite = (TestSuite) AllTestSuite.suite("src/test", "groovy/*Test.groovy");
18 String osName = System.getProperty("os.name");
19 if (osName.equals("Linux") || osName.equals("SunOS") || osName.equals("Solaris") || osName.equals("Mac OS X")) {
20 Class linuxTestClass = Class.forName("groovy.execute.ExecuteTest_LinuxSolaris");
21 suite.addTestSuite(linuxTestClass);
22 } else if (osName.equals("Windows 2000") || osName.equals("Windows 2003") || osName.equals("Windows XP") || osName.equals("Windows Vista")) {
23 Class windowsTestClass = Class.forName("groovy.execute.ExecuteTest_Windows");
24 suite.addTestSuite(windowsTestClass);
25 } else {
26 System.err.println("No execute tests for operating system: " + osName + "!!!");
29 return suite;
33 // The following classes appear in target/test-classes but do not extend junit.framework.TestCase
35 // AnotherMockInputStream.class
36 // Bean.class
37 // Bean249.class
38 // BooleanBean.class
39 // CallAnotherScript.class
40 // ClassWithScript.class
41 // ComparableFoo.class
42 // CreateData.class
43 // Entry.class
44 // EvalInScript.class
45 // Feed.class
46 // Foo.class
47 // HelloWorld.class
48 // HelloWorld2.class
49 // Html2Wiki.class
50 // IntegerCategory.class
51 // Loop.class
52 // Loop2.class
53 // MapFromList.class
54 // MarkupTestScript.class
55 // MethodTestScript.class
56 // MockInputStream.class
57 // MockProcess.class
58 // MockSocket.class
59 // OverloadA.class
60 // OverloadB.class
61 // NavToWiki.class
62 // Person.class
63 // SampleMain.class
64 // ScriptWithFunctions.class
65 // ShowArgs.class
66 // StringCategory.class
67 // SuperBase.class
68 // SuperDerived.class
69 // TestBase.class
70 // TestCaseBug.class
71 // TestDerived.class
72 // TinyAgent.class
73 // UnitTestAsScript.class
74 // UseClosureInScript.class
75 // X.class
76 // createLoop.class