Attributes attributes = createPerson( "cn" );
String oldRdn = getRdn( attributes, "cn" );
String newRdn = getRdn( attributes, "cn", "sn" );
ctx.addToEnvironment( "java.naming.ldap.deleteRDN", "false" );
ctx.rename( oldRdn, newRdn );
// Check whether new Entry exists
DirContext newCtx = ( DirContext ) ctx.lookup( newRdn );
assertNotNull( newCtx );