DeviceCRUDListener implements DeviceStateProvider { @Override public void deviceRemoved(String deviceName) { m_pmaRegistry.deviceRemoved(deviceName); } DeviceCRUDListener(DeviceManager deviceManager, PmaRegistryImpl pmaRegistry); void init(); void destroy(); @Override void deviceAdded(String deviceName); @Override void deviceRemoved(String deviceName);  }
@Test public void testSessionFactoryIsCalledOnDeviceDelete() { verifyZeroInteractions(m_pmaRegistry); m_listener.deviceRemoved("device A"); verify(m_pmaRegistry).deviceRemoved("device A"); }