public void testToFormattedStringLineWrap()
{
LdifDnLine dnLine = LdifDnLine
.create( "cn=abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxy,ou=department,o=org,dc=example,dc=com" );
LdifFormatParameters formatParameters = new LdifFormatParameters( true, 78, "\n" );
String formattedString = dnLine.toFormattedString( formatParameters );
assertEquals( formattedString, "dn: cn=abcdefghijklmnopqrstuvwxyzabcdefghijklmnopqrstuvwxy,ou=department,o=org"
+ "\n ,dc=example,dc=com\n" );
}