mirror of
https://gitee.com/chinabugotech/hutool.git
synced 2025-07-21 15:09:48 +08:00
fix code
This commit is contained in:
@@ -19,6 +19,7 @@ public class MailAccountTest {
|
||||
final MailAccount account = GlobalMailAccount.INSTANCE.getAccount();
|
||||
account.getSmtpProps();
|
||||
|
||||
Assertions.assertNotNull(account.getPass());
|
||||
Assertions.assertNotNull(account.getCharset());
|
||||
Assertions.assertTrue(account.isSslEnable());
|
||||
}
|
||||
@@ -35,7 +36,7 @@ public class MailAccountTest {
|
||||
public void customPropertyTest() throws GeneralSecurityException {
|
||||
final MailAccount mailAccount = new MailAccount();
|
||||
mailAccount.setFrom("xxx@xxx.com");
|
||||
mailAccount.setPass("xxxxxx");
|
||||
mailAccount.setPass("xxxxxx".toCharArray());
|
||||
|
||||
mailAccount.setHost("smtp.aol.com");
|
||||
|
||||
|
@@ -53,7 +53,7 @@ public class MailTest {
|
||||
account.setSslEnable(true);
|
||||
account.setFrom("hutool@yeah.net");
|
||||
account.setUser("hutool");
|
||||
account.setPass("q1w2e3");
|
||||
account.setPass("q1w2e3".toCharArray());
|
||||
MailUtil.send(account, "hutool@foxmail.com", "测试", "<h1>邮件来自Hutool测试</h1>", true);
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user