摘要: 路径说明: 一、加载类目录下的配置文件 @RunWith(SpringJUnit4ClassRunner.class) @ContextConfiguration("classpath:applicationContext_test.xml") public class MyTest1 { @Aut 阅读全文
posted @ 2015-09-18 03:46 Tom1997 阅读(1337) 评论(0) 推荐(0) 编辑
摘要: 一、说明二、那么在JavaBean中如何通过@Autowired获取该实例呢?有两种方式:1.直接获取@RunWith(SpringJUnit4ClassRunner.class)@ContextConfiguration("classpath:applicationContext_test.xml... 阅读全文
posted @ 2015-09-18 03:20 Tom1997 阅读(1511) 评论(0) 推荐(0) 编辑