Ejemplo n.º 1
0
 /**
  * {@inheritDoc}
  *
  * @see org.junit.rules.TestWatcher#finished(org.junit.runner.Description)
  */
 @Override
 protected void finished(Description description) {
   log(
       "\n\t<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<\n\tFinished Test [%s.%s]\n\t<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<<\n",
       testClass.getSimpleName(), methodName);
   super.finished(description);
 }
    @Override
    protected void finished(final Description description) {
      super.finished(description);

      try {
        for (Liquibase liquibase : liquibaseList) {
          liquibase.rollback(1000, null);
        }
      } catch (Exception e) {
        e.printStackTrace();
        throw new Error(e);
      } finally {
        try {
          conn.close();
        } catch (Exception f) {
        }
      }
    }