### Question:
LdapSyncSpecEntity { public PrincipalType getPrincipalType() { return principalType; } LdapSyncSpecEntity(PrincipalType principalType, SyncType syncType, List<String> principalNames); PrincipalType getPrincipalType(); SyncType getSyncType(); List<String> getPrincipalNames();  }### Answer:
@Test public void testGetPrincipalType() throws Exception { LdapSyncSpecEntity entity = new LdapSyncSpecEntity(LdapSyncSpecEntity.PrincipalType.USERS, LdapSyncSpecEntity.SyncType.ALL, Collections.emptyList()); Assert.assertEquals(LdapSyncSpecEntity.PrincipalType.USERS, entity.getPrincipalType()); entity = new LdapSyncSpecEntity(LdapSyncSpecEntity.PrincipalType.GROUPS, LdapSyncSpecEntity.SyncType.ALL, Collections.emptyList()); Assert.assertEquals(LdapSyncSpecEntity.PrincipalType.GROUPS, entity.getPrincipalType()); }