@Test
public void testOnConfiguredWithSameUsers() {

    // Create a user in the DB before we call onConfigured
    final String existingUserIdentity= "existingUser";
    final String existingUserIdentifier = UUID.randomUUID().toString();
    createUser(existingUserIdentifier, existingUserIdentity);
    // Call onConfigured with same identity that already exists
    configureWithInitialUsers(existingUserIdentity);
    // Verify there is only one user
    final Set<User> users = userGroupProvider.getUsers();
    assertEquals(1, users.size());
    assertNotNull(users.stream().filter(u -> u.getIdentity().equals(existingUserIdentity)).findFirst().orElse(null));
}