### Question:
ServerGroupConfiguration implements ConnectionConfig { public char[] getBindPassword() { return instance.getPasswd().toCharArray(); } ServerGroupConfiguration(ServerGroup group, ServerInstance instance); String getBindDN(); char[] getBindPassword(); int getMaxConnections(); int getLdapHeartbeat(); Set<LDAPURL> getLDAPURLs();  }### Answer:
@Test public void shouldReturnPasswordFromInstance() { ServerInstance mockInstance = mock(ServerInstance.class); ServerGroup mockGroup = mock(ServerGroup.class); ServerGroupConfiguration config = new ServerGroupConfiguration(mockGroup, mockInstance); given(mockInstance.getPasswd()).willReturn(""); config.getBindPassword(); verify(mockInstance).getPasswd(); }