Automatic test cases generation from formal contracts

被引:0
|
作者
Gil, Samuel Jimenez [1 ]
Capel, Manuel I. [2 ]
Olea, Gabriel [2 ]
机构
[1] SatixFy Space Syst UK, Trident Unit 2, Styal Rd, Manchester M22 5XB, England
[2] Univ Granada, Dept Software Engn, ETSIIT, Granada 18071, Spain
关键词
Automatic test cases generation; Software testing; Formal methods; Software verification;
D O I
10.1016/j.infsof.2024.107467
中图分类号
TP [自动化技术、计算机技术];
学科分类号
0812 ;
摘要
Context: Software verification for critical systems is facing an unprecedented cost increase due to the large amount of software packed in multicore platforms generally. A substantial amount of the verification efforts are dedicated to testing. Spark/Ada is a language often employed in safety -critical systems due to its high reliability. Formal contracts are often inserted in Spark's program specification to be used by a static theorem prover that checks whether the specification conforms with the implementation. However, this static analysis has its limitations as certain bugs can only be spotted through software testing. Objective: The main goal of our work is to use these formal contracts in Spark as input for a test oracle - whose method we describe - to generate test cases. Subsequent objectives consist of a) arguing about the traceability to comply with safety -critical software standards such as DO -178C for civil avionics and b) embracing the best -established software testing methods for these systems. Method: Our test generation method reads Spark formal contracts and applies Equivalence Class Partitioning with Boundary Analysis as a software testing method generating traceable test cases. Results: The evaluation, which uses an array of open -source examples of Spark contracts, shows a high level of passed test cases and statement coverage. The results are also compared against a random test generator. Conclusion: The proposed method is very effective at achieving a high number of passed test cases and coverage. We make the case that the effort to create formal specifications for Spark can be used both for proof and (automatic) testing. Lastly, we noticed that some formal contracts are more suitable than others for our test generation.
引用
收藏
页数:13
相关论文
共 50 条
  • [1] Automatic Generation of Test Cases from Formal Specifications using Mutation Testing
    Jaramillo Cajica, Roman
    Gonzalez Torres, Raul Ernesto
    Mejia Alvarez, Pedro
    2021 18TH INTERNATIONAL CONFERENCE ON ELECTRICAL ENGINEERING, COMPUTING SCIENCE AND AUTOMATIC CONTROL (CCE 2021), 2021,
  • [2] Progress of Software Vulnerability Identification and Automatic Test Cases Generation
    Huang, Zhao
    Huang, Shuguang
    Deng, Zhaokun
    2018 EIGHTH INTERNATIONAL CONFERENCE ON INSTRUMENTATION AND MEASUREMENT, COMPUTER, COMMUNICATION AND CONTROL (IMCCC 2018), 2018, : 1107 - 1111
  • [3] Automated Generation of Integration Test Sequences from Logical Contracts
    Xu, Dianxiang
    Xu, Weifeng
    Tu, Manghui
    2014 38TH ANNUAL IEEE INTERNATIONAL COMPUTER SOFTWARE AND APPLICATIONS CONFERENCE WORKSHOPS (COMPSACW 2014), 2014, : 632 - 637
  • [4] Generation of Automatic Test Cases with Mutation Analysis and Hybrid Genetic Algorithm
    Khan, Rijwan
    Amjad, Mohd
    Srivastava, Akhilesh Kumar
    2017 3RD IEEE INTERNATIONAL CONFERENCE ON COMPUTATIONAL INTELLIGENCE & COMMUNICATION TECHNOLOGY (CICT), 2017,
  • [5] Testing object-oriented programs: from formal specification to test scenario generation
    Chang, KH
    Liao, SS
    Seidman, SB
    Chapman, R
    JOURNAL OF SYSTEMS AND SOFTWARE, 1998, 42 (02) : 141 - 151
  • [6] Prototype of Test Cases Automatic Generation Tool BWDM Based on Boundary Value Analysis with VDM plus
    Tachiyama, Hiroki
    Katayama, Tetsuro
    Kita, Yoshihiro
    Yamaba, Hisaaki
    Okazaki, Naonobu
    ICAROB 2017: PROCEEDINGS OF THE 2017 INTERNATIONAL CONFERENCE ON ARTIFICIAL LIFE AND ROBOTICS, 2017, : P275 - P278
  • [7] A survey on mutation testing methods, fault classifications and automatic test cases generation
    Jeevarathinam, R.
    Thanamani, Antony Selvadoss
    JOURNAL OF SCIENTIFIC & INDUSTRIAL RESEARCH, 2011, 70 (02): : 113 - 117
  • [8] Automatic Test Cases Generation for C Written Programs Using Model Checking
    Gonzalez Lima, Daniset
    Gonzalez Torres, Raul E.
    Mejia Alvarez, Pedro
    2021 INTERNATIONAL CONFERENCE ON COMPUTATIONAL SCIENCE AND COMPUTATIONAL INTELLIGENCE (CSCI 2021), 2021, : 1944 - 1950
  • [9] Automatic generation of test cases algorithm design and implementation for fuze software testing
    Lou, WZ
    Wang, LP
    ISTM/2005: 6th International Symposium on Test and Measurement, Vols 1-9, Conference Proceedings, 2005, : 2037 - 2040
  • [10] Automatic Test Case Generation from Usage Information
    Silva, Pedro
    Paiva, Ana C. R.
    Restivo, Andre
    Garcia, Jorge Esparteiro
    2018 11TH INTERNATIONAL CONFERENCE ON THE QUALITY OF INFORMATION AND COMMUNICATIONS TECHNOLOGY (QUATIC), 2018, : 268 - 271