@Test
    public void testFlatIntoOneProfileNAnonymousProfiles() {
        final List<CommonProfile> profiles = Arrays.asList( null, AnonymousProfile.INSTANCE, null, AnonymousProfile.INSTANCE );
        assertEquals(AnonymousProfile.INSTANCE, ProfileHelper.flatIntoOneProfile(profiles).get());
    }
Tests {@link ProfileHelper}.

@author Jerome Leleu
@since 1.9.0
pac4j-core/src/test/java/org/pac4j/core/profile/ProfileHelperTests.java