@Test(timeout = 10000)
public void testSetConf() throws Exception {

  Configuration conf = getBaseConf(TEST_LDAP_URL);
  Configuration mockConf = Mockito.spy(conf);
  when(mockConf.getPassword(anyString()))
      .thenThrow(new IOException("injected IOException"));
  LdapGroupsMapping groupsMapping = getGroupsMapping();
  groupsMapping.setConf(mockConf);
}