private static void verifySerialization(final Collection<AuthenticationPolicy> policy) throws IOException {
        val file = new File(FileUtils.getTempDirectoryPath(), UUID.randomUUID() + ".json");
        MAPPER.writeValue(file, policy);
        val readPolicy = MAPPER.readValue(file, Collection.class);
        assertEquals(policy, readPolicy);
    }
This is {@link CoreAuthenticationUtilsTests}.

@author Misagh Moayyed
@since 5.2.0
core/cas-server-core-authentication/src/test/java/org/apereo/cas/authentication/CoreAuthenticationUtilsTests.java