Continue structural port from Spring Boot to Undertow

- Notification template generator
- Add tests for email notification handler
This commit is contained in:
Max Dor
2018-12-30 16:45:30 +01:00
parent 7ad985fead
commit ace5918342
5 changed files with 100 additions and 15 deletions

View File

@@ -28,10 +28,10 @@ public class EmailTemplateConfig extends GenericTemplateConfig {
private transient final Logger log = LoggerFactory.getLogger(EmailTemplateConfig.class);
public EmailTemplateConfig() {
setInvite("classpath:threepids/email/invite-template.eml");
getGeneric().put("matrixId", "classpath:threepids/email/mxid-template.eml");
getSession().getValidation().setLocal("classpath:threepids/email/validate-local-template.eml");
getSession().getValidation().setRemote("classpath:threepids/email/validate-remote-template.eml");
setInvite("classpath:/threepids/email/invite-template.eml");
getGeneric().put("matrixId", "classpath:/threepids/email/mxid-template.eml");
getSession().getValidation().setLocal("classpath:/threepids/email/validate-local-template.eml");
getSession().getValidation().setRemote("classpath:/threepids/email/validate-remote-template.eml");
}
public EmailTemplateConfig build() {

View File

@@ -28,10 +28,10 @@ public class PhoneSmsTemplateConfig extends GenericTemplateConfig {
private transient final Logger log = LoggerFactory.getLogger(EmailTemplateConfig.class);
public PhoneSmsTemplateConfig() {
setInvite("classpath:threepids/sms/invite-template.txt");
getGeneric().put("matrixId", "classpath:threepids/email/mxid-template.eml");
getSession().getValidation().setLocal("classpath:threepids/sms/validate-local-template.txt");
getSession().getValidation().setRemote("classpath:threepids/sms/validate-remote-template.txt");
setInvite("classpath:/threepids/sms/invite-template.txt");
getGeneric().put("matrixId", "classpath:/threepids/email/mxid-template.eml");
getSession().getValidation().setLocal("classpath:/threepids/sms/validate-local-template.txt");
getSession().getValidation().setRemote("classpath:/threepids/sms/validate-remote-template.txt");
}
public PhoneSmsTemplateConfig build() {