protected void shutDown(String testName) {
        Connection conn = null;
        Statement sql = null;
        DataSource ds = dsMap.get(testName);
        try {
            Connection c = ds.getConnection();
            Statement s = c.createStatement();
            s.executeUpdate("SHUTDOWN");
        } catch (SQLException ex) {
            // ignore
        } finally {
            JdbcUtils.closeStatement(sql);
            JdbcUtils.closeConnection(conn);
            dsMap.remove(testName);
            realmMap.remove(testName);
        }
    }
Shuts down the database and removes the realm from the realm map.
core/src/test/java/org/apache/shiro/realm/jdbc/JDBCRealmTest.java