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] AUTOMATIC-GENERATION OF TEST SCRIPTS FROM FORMAL TEST SPECIFICATIONS
    BALCER, MJ
    HASLING, WM
    OSTRAND, TJ
    PROCEEDINGS OF THE ACM SIGSOFT 89: THIRD SYMPOSIUM ON SOFTWARE TESTING, ANALYSIS, AND VERIFICATION ( TAV 3 ), 1989, 14 : 210 - 218
  • [3] AUTOMATIC GENERATION OF TEST CASES
    HANFORD, KV
    IBM SYSTEMS JOURNAL, 1970, 9 (04) : 242 - &
  • [4] Automatic Test Cases Generation from Software Specifications
    Alhroob, Aysh
    Dahal, Keshav
    Hossain, Alamgir
    E-INFORMATICA SOFTWARE ENGINEERING JOURNAL, 2010, 4 (01) : 109 - 121
  • [5] Test cases generation based on formal specification
    State Key Laboratory for Novel Software Technology, Nanjing University, Nanjing 210093, China
    不详
    Jiefangjun Ligong Daxue Xuebao, 2009, 4 (318-323):
  • [6] Automatic test cases generation from business process models
    Seqerloo, Arezoo Yazdani
    Amiri, Mohammad Javad
    Parsa, Saeed
    Koupaee, Mahnaz
    REQUIREMENTS ENGINEERING, 2019, 24 (01) : 119 - 132
  • [7] Automatic test cases generation from business process models
    Arezoo Yazdani Seqerloo
    Mohammad Javad Amiri
    Saeed Parsa
    Mahnaz Koupaee
    Requirements Engineering, 2019, 24 : 119 - 132
  • [8] Automatic Transformation from Formal Specifications to Functional Scenario Forms for Automatic Test Case Generation
    Liu, Shaoying
    Hayashi, Toshinori
    Takahashi, Kazuhiro
    Kimura, Koichiro
    Nakayama, Toshihiro
    Nakajima, Shin
    NEW TRENDS IN SOFTWARE METHODOLOGIES, TOOLS AND TECHNIQUES, 2010, 217 : 383 - 397
  • [9] Automatic test cases generation based on OCL
    Xie Xuanang
    Zhang Yunhua
    Jiang Zhongwei
    PROCEEDINGS OF THE FIRST INTERNATIONAL SYMPOSIUM ON TEST AUTOMATION & INSTRUMENTATION, VOLS 1 - 3, 2006, : 1170 - 1175
  • [10] Automatic Acceptance Test Case Generation From Essential Use Cases
    Kamalrudin, Massila
    Nor Aiza, M.
    Grundy, John
    Hosking, John
    Robinson, Mark
    NEW TRENDS IN SOFTWARE METHODOLOGIES, TOOLS AND TECHNIQUES, 2014, 265 : 246 - 255