01: /*
02: * Copyright (C) 1999-2004 <A href="http://www-ist.massey.ac.nz/JBDietrich" target="_top">Jens Dietrich</a>
03: *
04: * This library is free software; you can redistribute it and/or
05: * modify it under the terms of the GNU Lesser General Public
06: * License as published by the Free Software Foundation; either
07: * version 2 of the License, or (at your option) any later version.
08: *
09: * This library is distributed in the hope that it will be useful,
10: * but WITHOUT ANY WARRANTY; without even the implied warranty of
11: * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12: * Lesser General Public License for more details.
13: *
14: * You should have received a copy of the GNU Lesser General Public
15: * License along with this library; if not, write to the Free Software
16: * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
17: */
18: package test.org.mandarax.reference;
19:
20: import junit.framework.Test;
21: import junit.framework.TestSuite;
22:
23: import org.mandarax.reference.KnowledgeBase;
24:
25: /**
26: * Defines a test suite for all tests testing the knowledge base.
27: * Further tests for the knowledge base are part of the inference engine test suite.
28: * @see org.mandarax.reference.KnowledgeBase
29: * @see test.org.mandarax.reference.ResolutionInferenceEngineTests
30: * @author <A href="http://www-ist.massey.ac.nz/JBDietrich" target="_top">Jens Dietrich</A>
31: * @version 3.4 <7 March 05>
32: * @since 1.2
33: */
34: public class KnowledgeBaseTests {
35:
36: /**
37: * Launch the test suite. See TestRunner for interpretation
38: * of command line parameters.
39: * @see test.org.mandarax.testsupport.TestRunner
40: * @param args parameters
41: */
42: public static void main(String[] args) {
43: test.org.mandarax.testsupport.TestRunner.run(
44: KnowledgeBaseTests.class, args);
45: }
46:
47: /**
48: * Get the test suite.
49: * @return the test suite
50: */
51: public static Test suite() {
52: TestSuite suite = new TestSuite(
53: "Test cases for the mandarax reference implementation of a knowledge base");
54:
55: // testing the knowledge base
56: suite.addTest(new TestKnowledgeBaseAddClause1(
57: new KnowledgeBase()));
58: suite.addTest(new TestKnowledgeBaseAddClause2(
59: new KnowledgeBase()));
60: suite.addTest(new TestKnowledgeBaseRemoveClause1(
61: new KnowledgeBase()));
62: suite.addTest(new TestKnowledgeBaseRemoveClause2(
63: new KnowledgeBase()));
64: suite.addTest(new TestKnowledgeBaseRemoveClause3(
65: new KnowledgeBase()));
66: suite.addTest(new TestKnowledgeBaseRemoveClause4(
67: new KnowledgeBase()));
68: suite.addTest(new TestKnowledgeBaseRemoveClause5(
69: new KnowledgeBase()));
70: suite
71: .addTest(new TestKnowledgeBaseEvents1(
72: new KnowledgeBase()));
73: suite
74: .addTest(new TestKnowledgeBaseOrRules(
75: new KnowledgeBase()));
76:
77: return suite;
78: }
79: }
|