de.printStackTrace();
fail( de.getMessage() );
}
// Check the decoded ModifyDNResponse PDU
ModifyDnResponse modifyDnResponse = ldapMessageContainer.getMessage();
assertEquals( 1, modifyDnResponse.getMessageId() );
assertEquals( ResultCodeEnum.SUCCESS, modifyDnResponse.getLdapResult().getResultCode() );
assertEquals( "", modifyDnResponse.getLdapResult().getMatchedDn().getName() );
assertEquals( "", modifyDnResponse.getLdapResult().getErrorMessage() );
// Check the Control
Map<String, Control> controls = modifyDnResponse.getControls();
assertEquals( 1, controls.size() );
@SuppressWarnings("unchecked")
CodecControl<Control> control = (org.apache.directory.shared.ldap.codec.api.CodecControl<Control> )controls.get( "2.16.840.1.113730.3.4.2" );