基于Web应用前端行为模型的测试用例生成  被引量:1

Test Case Generation Based on Web Application Front-end Behavior Model

在线阅读下载全文

作  者:刘子文 虞莉娟[1] 苏义鑫[1] 赵耀 石柱 LIU Ziwen;YU Lijuan;SU Yixing;ZHAO Yao;SHI Zhu(School of Automation,Wuhan University of Technology,Wuhan 430070,China)

机构地区:[1]武汉理工大学自动化学院,武汉430070

出  处:《计算机科学》2023年第7期18-26,共9页Computer Science

基  金:国家自然科学基金(62176193)。

摘  要:基于Web应用前端模型的测试用例生成是Web应用测试的重要过程,但现有的大多数针对Web应用的模型都只关注Web页面及其事件,忽略了事件触发条件和后续动作。为了更准确地描述现代Web应用程序的动态行为,文中定义了一种新的Web应用前端行为模型(Front-end Behavior Model, FBM)。由于模型中迁移的触发条件可能存在内部变量,即迁移之间存在依赖关系,使得生成的测试用例不能按照输入序列执行,从而影响测试效果。为此,提出了一种优化分组遗传算法来实现可执行迁移路径FTP的自动生成,该算法考虑FTP生成问题的特点,对染色体初始化和适应度函数做出合理的设计,加入修补算子调整个体长度生成了满足迁移覆盖的FTP,并且通过引入自适应的遗传算子和模拟退火接收机制来减少迭代次数,从而加快求解速度。实验结果表明,该算法能够在更高的求解效率的基础上有效保证迁移路径的可行性以及覆盖率。Test case generation based on Web application front-end model is an important process of Web application testing,but most existing models for Web applications only focus on Web pages and their events,ignoring event triggering conditions and subsequent actions.Therefore,in order to describe the dynamic behavior of modern Web applications more accurately,this paper defines a new Web application front-end behavior model(FBM).Because there may be internal variables in the triggering conditions of transition in the model,that is,there are dependencies between transitions,which will make the generated test cases cannot be executed according to the input sequence,thus affecting the test results.Therefore,an optimized grouping genetic algorithm is proposed to automatically generate the feasible transition path(FTP).Considering the characteristics of FTP generation problem,the algorithm makes a reasonable design of chromosome initialization and fitness function,and adds a repair operator to adjust the individual length to generate FTP which satisfies the migration coverage.This paper also introduces an adaptive genetic operator and simulated annealing receiving mechanism to reduce the number of iterations,thus improving the solution speed.Experimental results show that the algorithm can effectively guarantee the feasibility and coverage of transition path on the basis of higher solution efficiency.

关 键 词:WEB应用测试 前端行为模型 可执行测试用例生成 分组遗传算法 

分 类 号:TP311.53[自动化与计算机技术—计算机软件与理论]

 

参考文献:

正在载入数据...

 

二级参考文献:

正在载入数据...

 

耦合文献:

正在载入数据...

 

引证文献:

正在载入数据...

 

二级引证文献:

正在载入数据...

 

同被引文献:

正在载入数据...

 

相关期刊文献:

正在载入数据...

相关的主题
相关的作者对象
相关的机构对象