KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > apache > commons > jxpath > JXPathTestSuite


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

16 package org.apache.commons.jxpath;
17
18 import junit.framework.Test;
19 import junit.framework.TestCase;
20 import junit.framework.TestSuite;
21 import junit.textui.TestRunner;
22
23 import org.apache.commons.jxpath.ri.JXPathCompiledExpressionTest;
24 import org.apache.commons.jxpath.ri.axes.RecursiveAxesTest;
25 import org.apache.commons.jxpath.ri.axes.SimplePathInterpreterTest;
26 import org.apache.commons.jxpath.ri.compiler.ContextDependencyTest;
27 import org.apache.commons.jxpath.ri.compiler.CoreFunctionTest;
28 import org.apache.commons.jxpath.ri.compiler.CoreOperationTest;
29 import org.apache.commons.jxpath.ri.compiler.ExtensionFunctionTest;
30 import org.apache.commons.jxpath.ri.compiler.VariableTest;
31 import org.apache.commons.jxpath.ri.model.MixedModelTest;
32 import org.apache.commons.jxpath.ri.model.beans.BeanModelTest;
33 import org.apache.commons.jxpath.ri.model.container.ContainerModelTest;
34 import org.apache.commons.jxpath.ri.model.dom.DOMModelTest;
35 import org.apache.commons.jxpath.ri.model.dynabeans.DynaBeanModelTest;
36 import org.apache.commons.jxpath.ri.model.dynamic.DynamicPropertiesModelTest;
37 import org.apache.commons.jxpath.ri.model.jdom.JDOMModelTest;
38 import org.apache.commons.jxpath.util.BasicTypeConverterTest;
39
40 /**
41  * <p>
42  * Test Suite for the JXPath class. The majority of these tests use
43  * instances of the TestBean class, so be sure to update the tests if you
44  * change the characteristics of that class.
45  * </p>
46  *
47  * <p>
48  * Note that the tests are dependent upon the static aspects
49  * (such as array sizes...) of the TestBean.java class, so ensure
50  * that all changes to TestBean are reflected here and in other JXPath tests.
51  * </p>
52  *
53  * @author Dmitri Plotnikov
54  * @version $Revision: 1.7 $ $Date: 2004/04/04 22:06:35 $
55  */

56
57 public class JXPathTestSuite extends TestCase {
58     private static boolean enabled = true;
59
60     /**
61      * Exercise the whole suite
62      */

63     public static void main(String JavaDoc args[]) {
64         TestRunner.run(suite());
65     }
66
67     public JXPathTestSuite(String JavaDoc name) {
68         super(name);
69     }
70
71     /**
72      * Return the tests included in this test suite.
73      */

74     public static Test suite() {
75         TestSuite suite = new TestSuite();
76         suite.addTestSuite(JXPathCompiledExpressionTest.class);
77         suite.addTestSuite(SimplePathInterpreterTest.class);
78         suite.addTestSuite(ContextDependencyTest.class);
79         suite.addTestSuite(CoreFunctionTest.class);
80         suite.addTestSuite(CoreOperationTest.class);
81         suite.addTestSuite(ExtensionFunctionTest.class);
82         suite.addTestSuite(VariableTest.class);
83         suite.addTestSuite(ContainerModelTest.class);
84         suite.addTestSuite(BeanModelTest.class);
85         suite.addTestSuite(DynamicPropertiesModelTest.class);
86         suite.addTestSuite(DOMModelTest.class);
87         suite.addTestSuite(DynaBeanModelTest.class);
88         suite.addTestSuite(JDOMModelTest.class);
89         suite.addTestSuite(MixedModelTest.class);
90         suite.addTestSuite(BasicTypeConverterTest.class);
91         suite.addTestSuite(RecursiveAxesTest.class);
92         return suite;
93     }
94 }
Popular Tags