public void init(TestConfig config, MockObjectTestCase testCase) throws Exception {
super.init(config, testCase);
// set the current testCase for our factory
MockFloppyDeviceFactory factory;
try {
factory = (MockFloppyDeviceFactory)
FloppyDriverUtils.getFloppyDeviceFactory();
} catch (NamingException ex) {
throw (IOException) new IOException().initCause(ex);
}
factory.setTestCase(testCase);
DeviceFinder deviceFinder = new FloppyControllerFinder();
StubDeviceManager.INSTANCE.removeAll();
StubDeviceManager.INSTANCE.add(deviceFinder, new FloppyDeviceToDriverMapper());