Augmenting Search-based Techniques with Static Synthesis-based Input Generation

Paulo Canelas, José Campos, C. Timperley, Alcides Fonseca
{"title":"Augmenting Search-based Techniques with Static Synthesis-based Input Generation","authors":"Paulo Canelas, José Campos, C. Timperley, Alcides Fonseca","doi":"10.1109/SBST52555.2021.00009","DOIUrl":null,"url":null,"abstract":"Automated test generation helps programmers to test their software with minimal intervention. Automated test generation tools produce a set of program inputs that maximize the possible execution paths, presented as a test coverage metric. Proposed approaches fall within three main approaches. Search-based methods work on any program by randomly searching for inputs that maximize coverage. Heuristic-based methods can be used to have better performance than pure random-search. Constraint-based methods use symbolic execution to restrict the random inputs to those guaranteed to explore different paths. Despite making the execution slower and supporting very few programs, these methods are more efficient because the search space is vastly reduced. The third approach combines the previous two to support any program and takes advantage of the space search reduction when able, at the cost of slower execution. We propose a fourth approach that also refines search-based with constraints. However, instead of requiring a slower symbolic execution when measuring coverage, constraints are statically extracted from the source code before the search procedure occurs. Our approach supports all programs (as in Search-Based) and reduces the search-space (as in Constraint-based methods). The innovation is that static analysis occurs only once and, despite being less exact that symbolic execution, it can significantly reduce the execution cost in every coverage measurement. This paper introduces this approach, describes how it can be implemented and discusses its advantages and drawbacks.","PeriodicalId":199085,"journal":{"name":"2021 IEEE/ACM 14th International Workshop on Search-Based Software Testing (SBST)","volume":"42 1","pages":"0"},"PeriodicalIF":0.0000,"publicationDate":"2021-05-01","publicationTypes":"Journal Article","fieldsOfStudy":null,"isOpenAccess":false,"openAccessPdf":"","citationCount":"0","resultStr":null,"platform":"Semanticscholar","paperid":null,"PeriodicalName":"2021 IEEE/ACM 14th International Workshop on Search-Based Software Testing (SBST)","FirstCategoryId":"1085","ListUrlMain":"https://doi.org/10.1109/SBST52555.2021.00009","RegionNum":0,"RegionCategory":null,"ArticlePicture":[],"TitleCN":null,"AbstractTextCN":null,"PMCID":null,"EPubDate":"","PubModel":"","JCR":"","JCRName":"","Score":null,"Total":0}
引用次数: 0

Abstract

Automated test generation helps programmers to test their software with minimal intervention. Automated test generation tools produce a set of program inputs that maximize the possible execution paths, presented as a test coverage metric. Proposed approaches fall within three main approaches. Search-based methods work on any program by randomly searching for inputs that maximize coverage. Heuristic-based methods can be used to have better performance than pure random-search. Constraint-based methods use symbolic execution to restrict the random inputs to those guaranteed to explore different paths. Despite making the execution slower and supporting very few programs, these methods are more efficient because the search space is vastly reduced. The third approach combines the previous two to support any program and takes advantage of the space search reduction when able, at the cost of slower execution. We propose a fourth approach that also refines search-based with constraints. However, instead of requiring a slower symbolic execution when measuring coverage, constraints are statically extracted from the source code before the search procedure occurs. Our approach supports all programs (as in Search-Based) and reduces the search-space (as in Constraint-based methods). The innovation is that static analysis occurs only once and, despite being less exact that symbolic execution, it can significantly reduce the execution cost in every coverage measurement. This paper introduces this approach, describes how it can be implemented and discusses its advantages and drawbacks.
基于静态合成的输入生成增强搜索技术
自动化测试生成帮助程序员以最少的干预来测试他们的软件。自动化的测试生成工具产生一组最大化可能的执行路径的程序输入,作为测试覆盖度量。提出的方法主要有三种。基于搜索的方法通过随机搜索最大覆盖率的输入来适用于任何程序。基于启发式的方法可以比纯随机搜索具有更好的性能。基于约束的方法使用符号执行将随机输入限制为保证探索不同路径的随机输入。尽管使执行速度变慢并且支持的程序很少,但这些方法更有效,因为搜索空间大大减少了。第三种方法结合了前两种方法来支持任何程序,并在可能的情况下利用空间搜索的减少,但代价是执行速度较慢。我们提出了第四种方法,它也改进了基于约束的搜索。然而,在测量覆盖率时,不需要较慢的符号执行,而是在搜索过程发生之前从源代码中静态地提取约束。我们的方法支持所有程序(如基于搜索的),并减少了搜索空间(如基于约束的方法)。创新之处在于,静态分析只发生一次,尽管不像符号执行那样精确,但它可以显著降低每次覆盖率度量中的执行成本。本文介绍了这种方法,描述了它的实现方法,并讨论了它的优点和缺点。
本文章由计算机程序翻译,如有差异,请以英文原文为准。
求助全文
约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学术官方微信