@Test
    void verifyOperation() {
        val result = SerializationUtils.serialize(100);
        assertThrows(ClassCastException.class,
            () -> SerializationUtils.deserializeAndCheckObject(result, String.class));
        assertThrows(ClassCastException.class,
            () -> SerializationUtils.deserialize(result, String.class));
        assertEquals(100, SerializationUtils.deserializeAndCheckObject(result, Integer.class));
        assertEquals(100, SerializationUtils.deserialize(result, Integer.class));
        assertEquals(100, SerializationUtils.deserializeAndCheckObject(result, Number.class));
        assertEquals(100, SerializationUtils.deserialize(result, Number.class));
    }
This is {@link SerializationUtilsTests}.

@author Misagh Moayyed
@since 6.3.0
core/cas-server-core-util-api/src/test/java/org/apereo/cas/util/serialization/SerializationUtilsTests.java