@Test
        void verifySubjectCanExpandWithVariables() throws Throwable {
            val emailRequest = EmailMessageRequest
                .builder()
                .context(CollectionUtils.wrap("name", "casuser"))
                .emailProperties(new EmailProperties().setSubject("Hello ${name}"))
                .build();
            val subject = emailSender.determineEmailSubject(emailRequest, mock(HierarchicalMessageSource.class));
            assertEquals("Hello casuser", subject);
            assertFalse(emailSender.send(emailRequest).isSuccess());
        }
This is {@link DefaultEmailSenderTests}.

@author Misagh Moayyed
@since 7.1.0
core/cas-server-core-notifications/src/test/java/org/apereo/cas/notifications/mail/DefaultEmailSenderTests.java