/** * This method will be run after every test as per @After. It will clean resources initialized by * the @Before methods. * * <p>Other methods can be annotated with @After here or in subclasses but no execution order is * guaranteed */ @After @Override public void destroy() { bf = null; bunknown = null; super.destroy(); }
/** * This method will be run before every test as per @Before. It will initialize resources required * for the tests. * * <p>Other methods can be annotated with @Before here or in subclasses but no execution order is * guaranteed */ @Before @Override public void init() { super.init(); try { bf = BitstreamFormat.find(context, 5); bunknown = BitstreamFormat.findUnknown(context); } catch (SQLException ex) { log.error("SQL Error in init", ex); fail("SQL Error in init: " + ex.getMessage()); } }