@@ -0,0 +1,1477 @@
+package org.sipfoundry.sipxconfig;%0A%0Aimport java.sql.SQLException;%0A%0Aimport junit.framework.TestCase;%0A%0Aimport org.dbunit.database.IDatabaseConnection;%0Aimport org.springframework.dao.DataIntegrityViolationException;%0A%0A/**%0A * Special TestCase class that catches and prints additional info for SQL exceptions that%0A * may happen during setUp, testXXX and tearDown.%0A * %0A * Alternatively we could just throw e.getNextException, but we may want to preserve the%0A * original exception.%0A */%0Apublic class SipxDatabaseTestCase extends TestCase %7B%0A    public void runBare() throws Throwable %7B%0A        try %7B%0A            super.runBare();%0A        %7D catch (SQLException e) %7B%0A            dumpSqlExceptionMessages(e);%0A            throw e;%0A        %7D catch (DataIntegrityViolationException e) %7B%0A            if (e.getCause() instanceof SQLException) %7B%0A                dumpSqlExceptionMessages((SQLException) e.getCause());%0A            %7D%0A            throw e;%0A        %7D%0A    %7D%0A%0A    private void dumpSqlExceptionMessages(SQLException e) %7B%0A        for (SQLException next = e; next != null; next = next.getNextException()) %7B%0A            System.err.println(next.getMessage());%0A        %7D%0A    %7D%0A%0A    protected IDatabaseConnection getConnection() throws Exception %7B%0A        return TestHelper.getConnection();%0A    %7D%0A    %0A    protected void tearDown() throws Exception %7B%0A        super.tearDown();%0A        %0A        // Comment this out for now, it is causing problems%0A//        TestHelper.closeConnection();%0A    %7D%0A%0A%7D%0A

Add db test base class that I forgot in my last checkin