@Test
public void testCompareToSameAva() throws LdapInvalidDnException
{
Ava atav1 = new Ava( schemaManager, "cn", "b" );
Ava atav2 = new Ava( schemaManager, "cn", "b" );
Ava atav3 = new Ava( schemaManager, "commonName", "b" );
Ava atav4 = new Ava( schemaManager, "2.5.4.3", " B " );
// 1 with others
assertEquals( 0, atav1.compareTo( atav1 ) );
assertEquals( 0, atav1.compareTo( atav2 ) );
assertEquals( 0, atav1.compareTo( atav3 ) );
assertEquals( 0, atav1.compareTo( atav4 ) );
// 2 with others
assertEquals( 0, atav2.compareTo( atav1 ) );
assertEquals( 0, atav2.compareTo( atav2 ) );
assertEquals( 0, atav2.compareTo( atav3 ) );
assertEquals( 0, atav2.compareTo( atav4 ) );
// 3 with others
assertEquals( 0, atav3.compareTo( atav1 ) );
assertEquals( 0, atav3.compareTo( atav2 ) );
assertEquals( 0, atav3.compareTo( atav3 ) );
assertEquals( 0, atav3.compareTo( atav4 ) );
// 4 with others
assertEquals( 0, atav4.compareTo( atav1 ) );
assertEquals( 0, atav4.compareTo( atav2 ) );
assertEquals( 0, atav4.compareTo( atav3 ) );
assertEquals( 0, atav4.compareTo( atav4 ) );
}