码迷,mamicode.com
首页 > 其他好文 > 详细

单元测试新方法:用setUp方法 @Before注释

时间:2017-12-29 14:58:56      阅读:127      评论:0      收藏:0      [点我收藏+]

标签:const   service   cep   测试   nts   equals   setup   public   for   

public class CentralizedPUDMatchServicePacTest {
PacMatchService pacMatchService;

@Before
public void setUp(){
pacMatchService = SpringTestHelper.get().getBean(PacMatchService.class);
}



@Test
public void testPacMatch(){

String pacAddress = "江苏省南京市玄武区珠江路435号";
DipanMatchBizAreaMatchMultiResponse response = pacMatchService.diPanMatch(pacAddress, "0000001");
// Assert.assertEquals(result.get(Constants.MATCHWAY),Constants.MATCHWAY_RANGE);
}

}

单元测试新方法:用setUp方法 @Before注释

标签:const   service   cep   测试   nts   equals   setup   public   for   

原文地址:https://www.cnblogs.com/hongming-blogs/p/8143341.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!