KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > cactus > TestShareAll


1 /*
2  * ========================================================================
3  *
4  * Copyright 2001-2004 The Apache Software Foundation.
5  *
6  * Licensed under the Apache License, Version 2.0 (the "License");
7  * you may not use this file except in compliance with the License.
8  * You may obtain a copy of the License at
9  *
10  * http://www.apache.org/licenses/LICENSE-2.0
11  *
12  * Unless required by applicable law or agreed to in writing, software
13  * distributed under the License is distributed on an "AS IS" BASIS,
14  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15  * See the License for the specific language governing permissions and
16  * limitations under the License.
17  *
18  * ========================================================================
19  */

20 package org.apache.cactus;
21
22 import org.apache.cactus.internal.TestAbstractCactusTestCase;
23 import org.apache.cactus.internal.TestWebTestResult;
24 import org.apache.cactus.internal.client.TestWebTestResultParser;
25 import org.apache.cactus.internal.configuration.ConfigurationInitializer;
26 import org.apache.cactus.internal.server.TestServletUtil;
27 import org.apache.cactus.internal.server.runner.TestXMLFormatter;
28 import org.apache.cactus.internal.util.TestCookieUtil;
29 import org.apache.cactus.internal.util.TestIoUtil;
30 import org.apache.cactus.internal.util.TestStringUtil;
31 import org.apache.cactus.internal.util.TestTestCaseImplementChecker;
32 import org.apache.cactus.internal.util.TestUniqueGenerator;
33 import org.apache.cactus.server.runner.TestServletTestRunner;
34
35 import junit.framework.Test;
36 import junit.framework.TestSuite;
37
38 /**
39  * Run all the unit tests of Cactus that do not need a servlet
40  * environment to run. These other tests will be exercised in the sample
41  * application.
42  *
43  * @version $Id: TestShareAll.java,v 1.1 2004/05/22 11:34:46 vmassol Exp $
44  */

45 public class TestShareAll
46 {
47     /**
48      * @return a test suite (<code>TestSuite</code>) that includes all shared
49      * tests
50      * @exception Exception on failure to load the cactus properties file
51      */

52     public static Test suite() throws Exception JavaDoc
53     {
54         TestSuite suite = new TestSuite(
55             "Cactus unit tests for all J2EE APIs");
56
57         // Make sure logging configuration properties are initialized so
58
// that it is possible to control logging from the outside of the
59
// tests.
60
ConfigurationInitializer.initialize();
61         
62         suite.addTestSuite(TestNoNameTestCase.class);
63         suite.addTestSuite(TestServletURL.class);
64         suite.addTestSuite(TestWebRequest.class);
65
66         suite.addTestSuite(TestAbstractCactusTestCase.class);
67         suite.addTestSuite(TestWebTestResult.class);
68
69         suite.addTestSuite(TestWebTestResultParser.class);
70                 
71         suite.addTestSuite(TestServletUtil.class);
72
73         suite.addTestSuite(TestXMLFormatter.class);
74
75         suite.addTestSuite(TestCookieUtil.class);
76         suite.addTestSuite(TestIoUtil.class);
77         suite.addTestSuite(TestStringUtil.class);
78         suite.addTestSuite(TestTestCaseImplementChecker.class);
79         suite.addTestSuite(TestUniqueGenerator.class);
80
81         suite.addTestSuite(TestServletTestRunner.class);
82
83         return suite;
84     }
85 }
86
Popular Tags