计算机应用 ›› 2015, Vol. 35 ›› Issue (7): 2009-2014.DOI: 10.11772/j.issn.1001-9081.2015.07.2009

• 计算机软件技术 • 上一篇    下一篇

基于UML图依权限有序的Web链接测试用例生成方法

张钜, 王曙燕, 孙家泽   

  1. 西安邮电大学 计算机学院, 西安 710061
  • 收稿日期:2015-01-04 修回日期:2015-03-24 出版日期:2015-07-10 发布日期:2015-07-17
  • 通讯作者: 王曙燕(1964-),女,河南南阳人,教授,博士,CCF会员,主要研究方向:软件测试、数据挖掘,wsylxj@126.com
  • 作者简介:张钜(1989-),女,山西朔州人,硕士研究生,主要研究方向:软件测试; 孙家泽(1980-),男,河南南阳人,副教授,博士研究生,主要研究方向:智能优化算法。
  • 基金资助:

    国家自然科学基金资助项目(61050003);陕西省教育厅项目(11JK1037)。

Generation method for Web link testing cases with permissions and sequence based on UML diagram

ZHANG Ju, WANG Shuyan, SUN Jiaze   

  1. School of Computer Science and Technology, Xi'an University of Posts and Telecommunications, Xi'an Shaanxi 710061, China
  • Received:2015-01-04 Revised:2015-03-24 Online:2015-07-10 Published:2015-07-17

摘要:

针对传统Web测试用例生成方法因缺少权限性和时序性考虑而产生的误判断问题,提出结合基于统一建模语言(UML)活动图与状态图,根据不同用户权限及交互活动流程分析Web页面链接而生成测试用例的方法。该方法生成含信息元素的扩展状态图,通过对扩展状态图的转换及相应路径的时序重排得到最终具有权限与时序性质的Web链接测试用例。通过实验分析,与缺少权限性和时序性考虑的Web测试用例生成方法相比,该方法有效地避免了测试中的误判断,在测试覆盖率、正确率及测试效率三方面均有明显的优势。实验结果表明,该方法有效地提高了Web测试的测试效率,增强了测试的可靠性与可行性。

关键词: 统一建模语言, 权限性, 时序性, Web测试, 链接测试

Abstract:

Aiming at the problem of erroneous judgement resulted from the lack of permission and time sequence considerations in traditional Web test case generation, a method combining the Unified Modeling Language (UML) activity diagram and statechart diagram was proposed,which generated testing cases according to the different users' permissions and interaction process analysis of Web page links. This proposed method generated extended statechart diagram containing information elements, got the final Web link testing cases with consideration of permission and sequence through transforming the extended statechart diagram and reordering the corresponding paths. In the comparison with the traditional Web testing case generation method which lacked the permission and time sequence considerations, this method avoids the erroneous judgement effectively and has obvious advantages in coverage, accuracy and efficiency.The experimental results show that the proposed method can improve the efficiency, reliability and feasibility of the Web test.

Key words: Unified Modeling Language (UML), permission, time sequence, Web test, link test

中图分类号: