BlueCov: Integrating Test Coverage and Model Checking with JBMC

被引:1
作者
Guedemann, Matthias [1 ]
Schrammel, Peter [2 ,3 ]
机构
[1] Munich Univ Appl Sci HM, Munich, Germany
[2] Univ Sussex, Oxford, England
[3] Diffblue Ltd, Oxford, England
来源
38TH ANNUAL ACM SYMPOSIUM ON APPLIED COMPUTING, SAC 2023 | 2023年
关键词
model-checking; test coverage; !text type='Java']Java[!/text;
D O I
10.1145/3555776.3577829
中图分类号
TP39 [计算机的应用];
学科分类号
081203 ; 0835 ;
摘要
Automated test case generation tools help businesses to write tests and increase the safety net provided by high regression test coverage when making code changes. Test generation needs to cover as much as possible of the uncovered code while avoiding generating redundant tests for code that is already covered by an existing test-suite. In this paper we present our work on a tool for the real world application of integrating formal analysis with automatic test case generation. The test case generation is based on coverage analysis using the Java bounded model checker (JBMC). Counterexamples of the model checker can be translated into Java method calls with specific parameters. In order to avoid the generation of redundant tests, it is necessary to measure the coverage in the exact same way as JBMC generates its coverage goals. Each existing coverage measurement tool uses a slightly different instrumentation and thus a different coverage criterion. This makes integration with a test case generator based on formal analysis difficult. Therefore, we developed BlueCov as a specific runtime coverage measurement tool which uses the exact same coverage criteria as JBMC does. This approach also allows for incremental test-case generation, only generating test coverage for previously untested code, e.g., to complete existing test suites.
引用
收藏
页码:1695 / 1697
页数:3
相关论文
共 14 条
  • [1] Beyer D., 2012, P ACM SIGSOFT 20 INT, P57, DOI DOI 10.1145/2393596.2393664
  • [2] Automatic Verification of C and Java']Java Programs: SV-COMP 2019
    Beyer, Dirk
    [J]. TOOLS AND ALGORITHMS FOR THE CONSTRUCTION AND ANALYSIS OF SYSTEMS, PT III, 2019, 11429 : 133 - 155
  • [3] Automating Test-Suite Augmentation
    Bloem, Roderick
    Koenighofer, Robert
    Roeck, Franz
    Tautschnig, Michael
    [J]. 2014 14TH INTERNATIONAL CONFERENCE ON QUALITY SOFTWARE (QSIC 2014), 2014, : 67 - 72
  • [4] Cordeiro Lucas C., 2018, ACM SIGSOFT Software Engineering Notes, V43, DOI 10.1145/3282517.3282529
  • [5] JBMC: Bounded Model Checking for Java']Java Bytecode (Competition Contribution)
    Cordeiro, Lucas
    Kroening, Daniel
    Schrammel, Peter
    [J]. TOOLS AND ALGORITHMS FOR THE CONSTRUCTION AND ANALYSIS OF SYSTEMS, PT III, 2019, 11429 : 219 - 223
  • [6] JBMC: A Bounded Model Checking Tool for Verifying Java']Java Bytecode
    Cordeiro, Lucas
    Kesseli, Pascal
    Kroening, Daniel
    Schrammel, Peter
    Trtik, Marek
    [J]. COMPUTER AIDED VERIFICATION (CAV 2018), PT I, 2018, 10981 : 183 - 190
  • [7] Gudemann M., 2022, arXiv, DOI [10.48550/ARXIV.2212.14779, DOI 10.48550/ARXIV.2212.14779]
  • [8] Holzer A, 2009, LECT NOTES COMPUT SC, V5403, P151, DOI 10.1007/978-3-540-93900-9_15
  • [9] JaCoCo, Java code coverage
  • [10] Kroening D., 2014, TOOLS ALGORITHMS CON, P389, DOI [DOI 10.1007/978-3-642-54862-8_26, DOI 10.1007/978-3-642-54862-826, 10.1007/978-3-642-54862-8_26]