摘要
软件测试是一项重要的软件确认活动,通过运行测试用例,旨在发现软件中存在的错误,保证交付出高质量的软件。为保证水利业务应用系统的质量,需要在建设过程中对系统进行充分的测试。研究测试用例的生成方法,包括逻辑覆盖和基本路径测试等白盒测试技术,以及等价划分和边界值分析等黑盒测试技术。选择防汛信息查询模块,重点探讨使用白盒和黑盒测试技术对该模块进行测试用例的生成,再运行测试用例对系统进行测试。2种测试技术能够有效地检测出系统中存在的错误,使开发人员能够及时修正错误。
Software testing is an important software validation activity to reveal failures in software and release high-quality product by executing test cases. In order to ensure the quality of water business application system, complete testing should be executed during the construction of these systems. This paper carries out a research on the methods of generating test cases, which contain white-box testing and black-box testing. White-box testing includes logic coverage and basis path testing, and black-box testing includes equivalence partitioning and boundary value analysis. This paper discusses test cases generation of flood control information query module using white-box and black-box testing. Then these test cases are executed to test the module. These two testing techniques can detect failures in the system effectively, and developers can fix these failures in time.
引文
[1]水利部水利信息中心.国家防汛抗旱指挥系统二期工程初步设计报告[R].北京:水利部水利信息中心,2015:339-534.
[2]BERTOLINO A.Software testing research:Achievements,challenges,dreams[C]//Proceedings of future of software engineering IEEE.Washington DC,IEEE,2007:85-103.
[3]BEIZER B.Software testing techniques[M].2nd ed.Boston:International Thompson Computer Press,1990:1-5.
[4]MYERS J G,BADGETT T,SANDLER C.The art of software testing[M].3rd ed.New York:John Wiley&Sons,2012:14-20.
[5]PAGE A,JOHNSTON K,ROLLISON B.How we test software at microsoft[M].Redmond:Microsoft Press,2009:62-85.
[6]LUCCA GAD,FASOLINO A R.Testing web-based applications:The state of the art and future trends[J].Information&software technology,2005,2(12):1172-1186.
[7]PRESSMAN R S,MAXIM B R.Software engineering:Apractitioner’s approach[M].8th ed.Columbus:Mc GrawHill Education,2015:499-507.
[8]张海藩,牟永敏.软件工程导论[M].6版.北京:清华大学出版社,2015:162-176.
[9]MCCABE T.A software complexity measure[J].IEEEtransactions on software engineering,1976(2):308-320.
[10]水利部水文局.全国水文测站编码[S].北京:水利部水文局,2002:1-40.