X-Git-Url: https://code.wpia.club/?a=blobdiff_plain;f=tests%2Forg%2Fcacert%2Fgigi%2Femail%2FTestSendmail.java;h=d9af0a28f62e6fceaaefb998afc3466243cc6c5c;hb=9994af5b2aee70810acd1e4675c7a7c4a538a961;hp=f918e3fe11dbeb6698966cdc9ab200df92e8b453;hpb=16316c8617f9da0b1e20ad0f54ce33e381f4da39;p=gigi.git diff --git a/tests/org/cacert/gigi/email/TestSendmail.java b/tests/org/cacert/gigi/email/TestSendmail.java index f918e3fe..d9af0a28 100644 --- a/tests/org/cacert/gigi/email/TestSendmail.java +++ b/tests/org/cacert/gigi/email/TestSendmail.java @@ -55,7 +55,7 @@ public class TestSendmail extends ConfiguredTest { String subj = "subj-" + createUniqueName(); String msg = "msg-" + createUniqueName(); - EmailProvider.getInstance().sendmail(succmail, subj, msg, "system@cacert.org", "system@cacert.org", "Testtarget", "Testsender", null, false); + EmailProvider.getInstance().sendMail(succmail, subj, msg, "system@cacert.org", "Testtarget", "Testsender", null, false); try (Socket s = SSLSocketFactory.getDefault().createSocket(imap, 993);// PrintWriter pw = new PrintWriter(new OutputStreamWriter(s.getOutputStream(), "UTF-8"), true);// @@ -85,7 +85,7 @@ public class TestSendmail extends ConfiguredTest { imapUntil(br, "exp"); pw.println("log logout"); imapUntil(br, "log"); - assertThat(body, containsString("From: support@" + ServerConstants.getWwwHostName().replaceAll("^www.", ""))); + assertThat(body, containsString("From: " + ServerConstants.getSupportMailAddress())); assertThat(body, containsString("To: gigi-testuser@dogcraft.de")); assertThat(body, containsString("Subject: " + subj)); assertThat(body, containsString(Base64.getEncoder().encodeToString(msg.getBytes("UTF-8")))); @@ -110,7 +110,7 @@ public class TestSendmail extends ConfiguredTest { private void initSelfsign() throws GeneralSecurityException, CertificateException, IOException, NoSuchAlgorithmException, InvalidKeyException, NoSuchProviderException, SignatureException { assumeNotNull(getTestProps().getProperty("emailProvider.smtpHost"), getTestProps().getProperty("emailProvider.smtpPort")); Properties prop = new Properties(); - prop.setProperty("emailProvider", "org.cacert.gigi.email.Sendmail"); + prop.setProperty("emailProvider", "org.cacert.gigi.email.SendMail"); prop.setProperty("emailProvider.smtpHost", getTestProps().getProperty("emailProvider.smtpHost")); prop.setProperty("emailProvider.smtpPort", getTestProps().getProperty("emailProvider.smtpPort")); KeyPair kp = generateKeypair();