### Question:
DBDeviceStateManager extends DBManager<DeviceState> implements DeviceStateManager { @Override public final void updateState(final DeviceState state) throws DeviceStateManagerException { LOGGER.debug("updating state: {}", state); try { super.update(state); } catch (DBManagerException e) { throw new DeviceStateManagerException(e); } } DBDeviceStateManager(final SessionFactory sessionFactory); @Override final DeviceState saveState(final DeviceState state); @Override final DeviceState getState(final Device device, final Class<? extends DeviceState> clazz); @Override final List<DeviceState> getStates(final Device device); @Override final void updateState(final DeviceState state); @Override final boolean deleteState(final Device device, final Class<? extends DeviceState> clazz);  }### Answer:
@Test(expectedExceptions = NullPointerException.class) public void testUpdateStateWithNullState() { stateManager.updateState(null); }