01: /*
02: * Copyright 2001-2007 Geert Bevin <gbevin[remove] at uwyn dot com>
03: * Distributed under the terms of either:
04: * - the common development and distribution license (CDDL), v1.0; or
05: * - the GNU Lesser General Public License, v2.1 or later
06: * $Id: TestDbStatement.java 3634 2007-01-08 21:42:24Z gbevin $
07: */
08: package com.uwyn.rife.database;
09:
10: import com.uwyn.rife.database.exceptions.DatabaseException;
11: import com.uwyn.rife.tools.ExceptionUtils;
12: import junit.framework.TestCase;
13:
14: public class TestDbStatement extends TestCase {
15: private Datasource mDatasource = null;
16: private DbConnection mConnection = null;
17:
18: public TestDbStatement(Datasource datasource,
19: String datasourceName, String name) {
20: super (name);
21: mDatasource = datasource;
22: }
23:
24: public void setUp() {
25: try {
26: mConnection = mDatasource.getConnection();
27: } catch (DatabaseException e) {
28: assertTrue(ExceptionUtils.getExceptionStackTrace(e), false);
29: }
30: }
31:
32: public void tearDown() {
33: try {
34: mConnection.close();
35: } catch (DatabaseException e) {
36: assertTrue(ExceptionUtils.getExceptionStackTrace(e), false);
37: }
38: }
39:
40: public void testExecute() {
41: // FIXME : write unittests
42: }
43: }
|