@Test
    void verifyDoNotProceedWithTrustedDevices() throws Exception {
        val requestContext = MockRequestContext.create(applicationContext);
        val attributes = new LocalAttributeMap<>();
        attributes.put(MultifactorAuthenticationProvider.class.getName(), dummyProvider);
        requestContext.setCurrentEvent(new Event(this, "eventId", attributes));
        val principal = UUID.randomUUID().toString();
        val deviceFingerprint = deviceFingerprintStrategy.determineFingerprint(RegisteredServiceTestUtils.getAuthentication(principal),
            requestContext.getHttpServletRequest(), requestContext.getHttpServletResponse());
        var record = getMultifactorAuthenticationTrustRecord();
        record.setPrincipal(principal);
        record.setDeviceFingerprint(deviceFingerprint);
        record.setMultifactorAuthenticationProvider(dummyProvider.getId());
        record = getMfaTrustEngine().save(record);
        WebUtils.putAuthentication(RegisteredServiceTestUtils.getAuthentication(record.getPrincipal()), requestContext);
        requestContext.setRequestCookiesFromResponse();
        val shouldProceed = mfaTrustProviderSelectionCriteria.shouldProceedWithMultifactorProviderSelection(requestContext);
        assertFalse(shouldProceed);
        assertTrue(requestContext.getFlashScope().contains("mfaProvider"));
    }
This is {@link MultifactorAuthenticationTrustProviderSelectionCriteriaTests}.

@author Misagh Moayyed
@since 7.0.0
support/cas-server-support-trusted-mfa/src/test/java/org/apereo/cas/trusted/web/flow/MultifactorAuthenticationTrustProviderSelectionCriteriaTests.java