@Override
    public void close() throws LiquibaseException {
        LiquibaseException exception = null;
        try {
            super.close();
        } finally {
            try {
                dataSource.stop();
            } catch (Exception e) {
                exception = new LiquibaseException(e);
            }
        }

        if (exception != null) {
            throw exception;
        }
    }
@Test
    void testWhenClosingAllConnectionsInPoolIsReleased() throws Exception {

        ConnectionPool pool = dataSource.getPool();
        assertThat(pool.getActive()).isEqualTo(1);

        liquibase.close();

        assertThat(pool.getActive()).isZero();
        assertThat(pool.getIdle()).isZero();
        assertThat(pool.isClosed()).isTrue();
    }