@Test(dependsOnMethods = "testAddUsersMembers")
public void testUserGetPrincipals() {

    metadata.read(() -> {
        User user1 = this.provider.findUserBySystemName("user1").get();
        User user2 = this.provider.findUserBySystemName("user2").get();
        User user3 = this.provider.findUserBySystemName("user3").get();
        assertThat(user1.getPrincipal()).isEqualTo(new UsernamePrincipal("user1"));
        assertThat(user2.getPrincipal()).isEqualTo(new UsernamePrincipal("user2"));
        assertThat(user3.getPrincipal()).isEqualTo(new UsernamePrincipal("user3"));
    });
}