@Test public void testLoadStepAttributes_closeInputStream() throws Exception { BaseStepMeta meta = new BaseStepMeta(); meta.loadStepAttributes(); RandomAccessFile fos = null; try { File file = new File( getClass().getResource( BaseStepMeta.STEP_ATTRIBUTES_FILE ).getPath() ); if ( file.exists() ) { fos = new RandomAccessFile( file, "rw" ); } } catch ( FileNotFoundException | SecurityException e ) { fail( "the file with properties should be unallocated" ); } finally { if ( fos != null ) { fos.close(); } } }
final StepMeta stepMeta = mock( StepMeta.class ); BaseStepMeta meta = new BaseStepMeta(); meta.setChanged( true ); meta.databases = new Database[] { db1, db2 };
final StepMeta stepMeta = mock( StepMeta.class ); BaseStepMeta meta = new BaseStepMeta(); meta.setChanged( true ); meta.databases = new Database[] { db1, db2 };