Is coverage a good measure of testing effectiveness?: An assessment using branch coverage and Random testing

Yi Wei, M. Oriol, B. Meyer
{"title":"Is coverage a good measure of testing effectiveness?: An assessment using branch coverage and Random testing","authors":"Yi Wei, M. Oriol, B. Meyer","doi":"10.3929/ETHZ-A-006859451","DOIUrl":null,"url":null,"abstract":"Most approaches to testing use branch coverage to decide on the quality of a given test suite. The intuition is that covering branches relates directly to uncovering faults. In this article we present an empirical study that applied random testing to 14 Eiffel classes for a total of 2520 hours and recorded the number of uncovered faults and the branch coverage over time. Our results show that: (1) in the tested classes, random testing reaches 93% branch coverage (2) it exercises almost the same set of branches every time, (3) it detects different faults from time to time, (4) during the first 10 minutes of testing while branch coverage increases rapidly, there is a strong correlation between branch coverage and the number of uncovered faults, (5) over 50% of the faults are detected at a time where branch coverage hardly changes and the correlation between branch coverage and the number of uncovered faults is weak. These results provide evidence that branch coverage is not a good stopping criterion for random testing. They also show that branch coverage is not a good indicator for the effectiveness of a test suite.","PeriodicalId":10841,"journal":{"name":"CTIT technical reports series","volume":"26 1","pages":""},"PeriodicalIF":0.0000,"publicationDate":"2010-01-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"12","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"CTIT technical reports series","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.3929/ETHZ-A-006859451","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 12

Abstract

Most approaches to testing use branch coverage to decide on the quality of a given test suite. The intuition is that covering branches relates directly to uncovering faults. In this article we present an empirical study that applied random testing to 14 Eiffel classes for a total of 2520 hours and recorded the number of uncovered faults and the branch coverage over time. Our results show that: (1) in the tested classes, random testing reaches 93% branch coverage (2) it exercises almost the same set of branches every time, (3) it detects different faults from time to time, (4) during the first 10 minutes of testing while branch coverage increases rapidly, there is a strong correlation between branch coverage and the number of uncovered faults, (5) over 50% of the faults are detected at a time where branch coverage hardly changes and the correlation between branch coverage and the number of uncovered faults is weak. These results provide evidence that branch coverage is not a good stopping criterion for random testing. They also show that branch coverage is not a good indicator for the effectiveness of a test suite.
覆盖率是测试有效性的良好度量吗?:使用分支覆盖和随机测试的评估
大多数测试方法使用分支覆盖率来决定给定测试套件的质量。直观的感觉是,覆盖分支与发现错误直接相关。在本文中,我们提出了一项实证研究,对14个Eiffel班进行随机测试,共计2520小时,并记录了未发现故障的数量和分支覆盖率随时间的变化。我们的结果表明:(1)在测试类中,随机测试的分支覆盖率达到93%;(2)每次测试的分支几乎相同;(3)每次检测到的故障不同;(4)在测试的前10分钟,当分支覆盖率迅速增加时,分支覆盖率与发现的故障数量之间存在很强的相关性;(5)超过50%的故障是在分支覆盖率变化不大的时间检测到的,分支覆盖率与未发现故障数的相关性较弱。这些结果提供了分支覆盖率不是随机测试的良好停止标准的证据。它们还表明,分支覆盖率并不是测试套件有效性的良好指示器。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约1分钟内获得全文 求助全文
来源期刊
自引率
0.00%
发文量
0
×
引用
GB/T 7714-2015
复制
MLA
复制
APA
复制
导出至
BibTeX EndNote RefMan NoteFirst NoteExpress
×
提示
您的信息不完整,为了账户安全,请先补充。
现在去补充
×
提示
您因"违规操作"
具体请查看互助需知
我知道了
×
提示
确定
请完成安全验证×
copy
已复制链接
快去分享给好友吧!
我知道了
右上角分享
点击右上角分享
0
联系我们:info@booksci.cn Book学术提供免费学术资源搜索服务,方便国内外学者检索中英文文献。致力于提供最便捷和优质的服务体验。 Copyright © 2023 布克学术 All rights reserved.
京ICP备2023020795号-1
ghs 京公网安备 11010802042870号
Book学术文献互助
Book学术文献互助群
群 号:481959085
Book学术官方微信