public List<RoleDO> getRoles() {
        return ((Collection<?>) getSource())
                .stream()
                .map(RoleDO.class::cast)
                .collect(Collectors.toList());
    }
@Test
    public void testGetRoles() {
        List<RoleDO> roles = batchRoleDeletedEventTest.getRoles();
        assertEquals(roles, roleDOList);

        List<RoleDO> emptyRoles = batchRoleDeletedEventEmptySourceTest.getRoles();
        assertEquals(emptyRoles, emptyRoleDOList);
    }