基于用户会话的Web测试用例生成及优化研究
发布时间:2018-04-28 08:40
本文选题:用户会话 + Web测试用例 ; 参考:《中国矿业大学》2014年硕士论文
【摘要】:随着Web应用系统广泛应用于教育、商业、工业等领域,Web系统变得越来越复杂,一个项目的失败将可能导致Web危机的发生。在Web工程过程中,基于Web系统的测试任务是一项重要而富有挑战性的工作,也越来越得到人们的关注与重视。Web测试需要从最终用户的角度对Web应用系统进行可用性及安全性测试,基于用户会话的Web测试技术综合考虑了用户的访问行为与访问兴趣等因素,测试过程结合用户的真实数据,避免了模拟用户行为带来的测试偏差,极大的增加了测试的有效性。 Web测试的数据来源于IIS服务器,首先将Web应用站点通过IIS服务器发布,并对日志记录按需设置,经过用户访问站点生成日志文件并进行数据采集;然后通过行删除和列删除两项工作对日志数据进行数据清洗,删除文件中冗余的信息;其次利用用户IP、代理类型和引用页面集对数据中的隐含用户进行识别,并利用时间阈值法对数据信息进行划分形成用户会话;最后通过不同的测试用例生成策略生成原始的测试用例集。 由于测试用例集合中存在着大量冗余的测试用例,这使测试过程在资源及成本方面存在着很大的浪费问题,所以测试用例优化工作是必不可少的。首先利用页面集合和会话集合得到页面访问矩阵V;其次应用K-means算法将矩阵化的数据信息进行划分,得到合理的聚类集合;最后通过约简方法从各个分组中选出代表性实例组成优化测试用例集。针对新增数据信息则采用马氏增量聚类进行处理,,将原始聚类集的k个中心点作为增量聚类的初始聚类中心,对新增数据进行划分,并不断调整变化的聚类集最终完成增量聚类。 通过对开源Web应用系统(Bookshop)进行处理分析,并结合测试用例生成及优化技术对数据进行处理,通过对原始用例集和约简用例集的比较分析,证实约简技术的应用既能维持测试用例集的功能覆盖率与错误检测率,又能减少了资源及成本的消耗。
[Abstract]:As Web applications become more and more complex in the fields of education, commerce, industry and so on, the failure of a project may lead to the occurrence of Web crisis. In the process of Web engineering, testing task based on Web system is an important and challenging task. More and more attention has been paid to the need to test the usability and security of Web applications from the point of view of end users. The Web testing technology based on user session takes into account the user's access behavior and access interest and so on. The testing process combines the user's real data to avoid the test deviation caused by simulating the user's behavior and greatly increases the effectiveness of the test. The data of the Web test comes from the IIS server. Firstly, the Web application site is published through the IIS server, and the log record is set up on demand, and the log file is generated through the user visiting the site and the data is collected. Then the log data is cleaned by row deletion and column deletion, and redundant information in the file is deleted. Secondly, the implicit users in the data are identified by means of user IPs, proxy types and reference page sets. The data information is divided into user sessions by time threshold method, and the original test case set is generated by different test case generation strategies. Because there are a lot of redundant test cases in the set of test cases, there is a great waste of resources and cost in the test process, so it is necessary to optimize the test cases. Firstly, the page access matrix is obtained by using the page set and session set, and then the K-means algorithm is used to divide the data information of the matrix to obtain a reasonable clustering set. Finally, we select representative examples from each group to form the optimized test case set by reduction method. The new data information is processed by Mahalanobis incremental clustering. The k centers of the original clustering set are taken as the initial clustering centers of the incremental clustering, and the new data are divided. Finally, the incremental clustering is completed by adjusting the changing clustering sets. Through processing and analysis of open source Web application system, and combining with test case generation and optimization technology, the data is processed, and the comparison between original use case set and reduction use case set is analyzed. It is proved that the application of reduction can not only maintain the function coverage and error detection rate of test case set, but also reduce the consumption of resources and cost.
【学位授予单位】:中国矿业大学
【学位级别】:硕士
【学位授予年份】:2014
【分类号】:TP393.09
【参考文献】
相关期刊论文 前10条
1 尹文洁;崔冬华;;测试用例集的约简方法研究[J];电脑开发与应用;2011年05期
2 吴琪;高滢;王晓涛;左万利;;一种基于距离的增量聚类算法[J];解放军理工大学学报(自然科学版);2005年06期
3 罗可,蔡碧野,吴一帆,谢中科,张丽;数据挖掘中聚类的研究[J];计算机工程与应用;2003年20期
4 许蕾;徐宝文;陈振强;;Web测试综述[J];计算机科学;2003年03期
5 李守振;张南平;常国锋;;Web应用分层与开发框架设计研究[J];计算机工程;2006年22期
6 武晋南;高建华;;基于用户行为和会话的Web应用测试方法[J];计算机工程;2010年08期
7 聂长海,徐宝文;一种最小测试用例集生成方法[J];计算机学报;2003年12期
8 郑宏亮;王建英;;一种基于Mahalanobis距离的增量聚类算法[J];计算机应用与软件;2011年12期
9 李桃迎;陈燕;秦胜君;李楠;;增量聚类算法综述[J];科学技术与工程;2010年35期
10 陈阳梅;丁晓明;;一种基于K中心点算法的测试用例集约简方法[J];计算机科学;2012年S1期
本文编号:1814558
本文链接:https://www.wllwen.com/guanlilunwen/ydhl/1814558.html