首页>代码>【demo】自己写的一个 SpringMail 异步发送邮件的demo。 javamail 邮件异步发送>/spring-mail/src/test/java/com/haohui/springmail/BaseTest.java
package com.haohui.springmail; import javax.annotation.Resource; import org.junit.runner.RunWith; import org.springframework.test.context.ContextConfiguration; import org.springframework.test.context.junit4.AbstractJUnit4SpringContextTests; import org.springframework.test.context.junit4.SpringJUnit4ClassRunner; /** * * Spring 集成测试基类 * * @RunWith(SpringJUnit4ClassRunner.class) //指定测试用例的运行器 这里是指定了Junit4 * @ContextConfiguration({"/spring-ds.xml", "/spring-mail.xml"}) //指定Spring的配置文件 /为classpath下 * * @author cevencheng * */ @RunWith(SpringJUnit4ClassRunner.class) //指定测试用例的运行器 这里是指定了Junit4 @ContextConfiguration({"/spring-ds.xml", "/spring-mail.xml"}) //指定Spring的配置文件 /为classpath下 public abstract class BaseTest extends AbstractJUnit4SpringContextTests { @Resource public MailService mailService = null; }

chenruofei1996 LV1
2020年8月17日
chengxuyuanb LV1
2019年10月16日
ZpongZ LV6
2019年10月6日
dyhqwe LV1
2019年8月1日
chennguo LV6
2019年4月24日
2469684164 LV10
2019年3月16日
zzuLXH LV2
2019年3月12日
tan18871439923 LV14
2018年10月31日
zongheng14 LV2
2018年10月20日
wcy071213 LV27
2018年6月14日