DefaultSyncedIdentity implements SyncedIdentity { @Nullable @Override public ExternalIdentityRef getExternalIdRef() { return ref; } DefaultSyncedIdentity(@NotNull String id, @Nullable ExternalIdentityRef ref, boolean isGroup, long lastSynced); @NotNull @Override String getId(); @Nullable @Override ExternalIdentityRef getExternalIdRef(); @Override boolean isGroup(); @Override long lastSynced(); @Override String toString();  }
@Test public void testGetExternalIdRef() { assertEquals(externalUser.getExternalId(), si.getExternalIdRef()); assertEquals(externalGroup.getExternalId(), siGroup.getExternalIdRef()); SyncedIdentity siNullExtRef = new DefaultSyncedIdentity(TestIdentityProvider.ID_TEST_USER, null, false, 234); assertNull(siNullExtRef.getExternalIdRef()); }