@Test
    void testGuestSingleRoleAssertion() throws Throwable {
        assertThrows(UnauthenticatedException.class, () -> {
            DenyAllAnnotationHandler handler = new DenyAllAnnotationHandler();

            Annotation denyAllAnnotation = new DenyAll() {
                @Override
                public Class<? extends Annotation> annotationType() {
                    return DenyAll.class;
                }
            };

            handler.assertAuthorized(denyAllAnnotation);
        });
    }
Test cases for the {@link DenyAllAnnotationHandler} class.
core/src/test/java/org/apache/shiro/authz/aop/DenyAllAnnotationHandlerTest.java