Property-Based Testing: Climbing the Stairway to Verification

被引:4
作者
Chen, Zilin [1 ]
Rizkallah, Christine [2 ]
O'Connor, Liam [3 ]
Susarla, Partha
Klein, Gerwin [1 ,4 ]
Heiser, Gernot [1 ]
Keller, Gabriele [5 ]
机构
[1] UNSW Sydney, Sydney, NSW, Australia
[2] Univ Melbourne, Melbourne, Vic, Australia
[3] Univ Edinburgh, Edinburgh, Midlothian, Scotland
[4] Proofcraft, Sydney, NSW, Australia
[5] Univ Utrecht, Utrecht, Netherlands
来源
PROCEEDINGS OF THE 15TH ACM SIGPLAN INTERNATIONAL CONFERENCE ON SOFTWARE LANGUAGE ENGINEERING, SLE 2022 | 2022年
关键词
QuickCheck; functional programming; formal verification; systems programming;
D O I
10.1145/3567512.3567520
中图分类号
TP31 [计算机软件];
学科分类号
081202 ; 0835 ;
摘要
Property-based testing (PBT) is a powerful tool that is widely available in modern programming languages. It has been used to reduce formal software verification effort. We demonstrate how PBT can be used in conjunction with formal verification to incrementally gain greater assurance in code correctness by integrating PBT into the verification framework of COGENT-a programming language equipped with a certifying compiler for developing high-assurance systems components. Specifically, for PBT and formal verification to work in tandem, we structure the tests to mirror the refinement proof that we used in COGENT's verification framework: The expected behaviour of the system under test is captured by a functional correctness specification, which mimics the formal specification of the system, andwe test the refinement relation between the implementation and the specification. We exhibit the additional benefits that this mutualism brings to developers and demonstrate the techniques we used in this style of PBT, by studying two concrete examples.
引用
收藏
页码:84 / 97
页数:14
相关论文
共 66 条
[1]  
AdaCore, 2022, SPARK Pro.
[2]   COGENT: Verifying High-Assurance File System Implementations [J].
Amani, Sidney ;
Hixon, Alex ;
Chen, Zilin ;
Rizkallah, Christine ;
Chubb, Peter ;
O'Connor, Liam ;
Beeren, Joel ;
Nagashima, Yutaka ;
Lim, Japheth ;
Sewell, Thomas ;
Tuong, Joseph ;
Keller, Gabriele ;
Murray, Toby ;
Klein, Gerwin ;
Heiser, Gernot .
ACM SIGPLAN NOTICES, 2016, 51 (04) :175-188
[3]  
Amani Sidney, 2015, WORKSH MOD FORM AN R, P1
[4]  
Amani Sidney, 2016, PhD Thesis
[5]  
[Anonymous], 2022, ACL2
[6]  
Arts T, 2015, IEEE ICST WORKSHOP
[7]   A CALCULUS OF REFINEMENTS FOR PROGRAM DERIVATIONS [J].
BACK, RJR .
ACTA INFORMATICA, 1988, 25 (06) :593-624
[8]  
Barendsen E., 1993, Foundations of Software Technology and Theoretical Computer Science. 13th Conference Proceedings, P41
[9]  
Behlendorf Brian, 2011, POSIX Filesystem Test Suite.
[10]   Random testing in Isabelle/HOL [J].
Berghofer, S ;
Nipkow, T .
PROCEEDINGS OF THE SECOND INTERNATIONAL CONFERENCE ON SOFTWARE ENGINEERING AND FORMAL METHODS, 2004, :230-239