KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > logicalcobwebs > proxool > configuration > PropertyConfiguratorTest


1 /*
2  * This software is released under a licence similar to the Apache Software Licence.
3  * See org.logicalcobwebs.proxool.package.html for details.
4  * The latest version is available at http://proxool.sourceforge.net
5  */

6 package org.logicalcobwebs.proxool.configuration;
7
8 import org.logicalcobwebs.proxool.AbstractProxoolTest;
9 import org.logicalcobwebs.proxool.ProxoolException;
10 import org.logicalcobwebs.proxool.ProxoolFacade;
11 import org.logicalcobwebs.proxool.TestHelper;
12
13 import java.sql.SQLException JavaDoc;
14
15 /**
16  * Tests that the PropertyConfigurator works.
17  *
18  * @version $Revision: 1.8 $, $Date: 2003/03/04 10:58:45 $
19  * @author Christian Nedregaard (christian_nedregaard@email.com)
20  * @author $Author: billhorsman $ (current maintainer)
21  * @since Proxool 0.6
22  */

23 public class PropertyConfiguratorTest extends AbstractProxoolTest {
24
25     /**
26      * @see junit.framework.TestCase#TestCase
27      */

28     public PropertyConfiguratorTest(String JavaDoc name) {
29         super(name);
30     }
31
32     /**
33      * Test that the configuration succeds and that all expected properties
34      * has been received by Proxool.
35      * @throws ProxoolException if the configuration fails.
36      * @throws SQLException if ProxoolFacade operation fails.
37      */

38     public void testPropertyConfigurator() throws ProxoolException, SQLException JavaDoc {
39         PropertyConfigurator.configure("src/java-test/org/logicalcobwebs/proxool/configuration/test.properties");
40         TestHelper.equalsCompleteAlternativeProperties(ProxoolFacade.getConnectionPoolDefinition("property-test"));
41         TestHelper.equalsCompleteAlternativeProperties(ProxoolFacade.getConnectionPoolDefinition("property-test-2"));
42         ProxoolFacade.removeConnectionPool("property-test");
43         ProxoolFacade.removeConnectionPool("property-test-2");
44
45     }
46
47 }
48
49 /*
50  Revision history:
51  $Log: PropertyConfiguratorTest.java,v $
52  Revision 1.8 2003/03/04 10:58:45 billhorsman
53  checkstyle
54
55  Revision 1.7 2003/03/04 10:24:41 billhorsman
56  removed try blocks around each test
57
58  Revision 1.6 2003/03/03 17:09:18 billhorsman
59  all tests now extend AbstractProxoolTest
60
61  Revision 1.5 2003/03/03 11:12:07 billhorsman
62  fixed licence
63
64  Revision 1.4 2003/03/01 15:27:25 billhorsman
65  checkstyle
66
67  Revision 1.3 2003/02/27 18:01:49 billhorsman
68  completely rethought the test structure. it's now
69  more obvious. no new tests yet though.
70
71  Revision 1.2 2003/02/19 15:14:27 billhorsman
72  fixed copyright (copy and paste error,
73  not copyright change)
74
75  Revision 1.1 2002/12/26 11:34:15 billhorsman
76  Init rev.
77
78 */

79
Popular Tags