Abstract
Program-based test-generation methods (also called “white-box” tests) are conventionally described in terms of a control flow graph and the generation of path conditions along the paths in this graph. In this paper, we present an alternative formalization based on state-exception monads that allows for direct derivations of path conditions from program presentations in them; the approach lends itself both for program-based testing procedures—designed to meet classical coverage criteria—and bounded verification. Our formalization is implemented in the Isabelle/HOL interactive theorem prover, where symbolic execution can be processed through tactics implementing test-generation strategies for various coverage criteria. The resulting environment is a major step towards testing support for the development of invariants and post-conditions in C verification environments similar to Isabelle/AutoCorres.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Notes
- 1.
A specific tactic that only calls the simplifier and applies elimination rules of connectives would work as well and be less powerful.
- 2.
See https://www.brucker.ch/projects/hol-testgen for more details, in particular the theory.
References
Blanchette, J.C., Nipkow, T.: Nitpick: a counterexample generator for higher-order logic based on a relational model finder. In: Kaufmann, M., Paulson, L.C. (eds.) ITP 2010. LNCS, vol. 6172, pp. 131–146. Springer, Heidelberg (2010). https://doi.org/10.1007/978-3-642-14052-5_11
Bockenek, J.A.: An extension of Isabelle/UTP with simpl-likecontrol flow. Ph.D. thesis, Virginia Polytechnic Institute and State University (2017)
Botella, B., Delahaye, M., Ha, S.H.T., Kosmatov, N., Mouy, P., Roger, M., Williams, N.: Automating structural testing of C programs: experience with pathcrawler. In: Proceedings of the 4th International Workshop on Automation of Software Test, AST 2009, Vancouver, BC, Canada, 18–19 May 2009, pp. 70–78 (2009)
Brucker, A.D., Wolff, B.: On theorem prover-based testing. Formal Asp. Comput. (FAOC) 25(5), 683–721 (2013)
Church, A.: A set of pustulates for the foundation of logic (1). Ann. Math. (1932)
Claessen, K., Hughes, J.: Testing monadic code with quickcheck. SIGPLAN Not. 37(12), 47–59 (2002)
de Halleux, J., Tillmann, N.: Parameterized unit testing with pex. In: Beckert, B., Hähnle, R. (eds.) TAP 2008. LNCS, vol. 4966, pp. 171–181. Springer, Heidelberg (2008). https://doi.org/10.1007/978-3-540-79124-9_12
Filieri, A., Pasareanu, C.S., Visser, W.: Reliability analysis in symbolic pathfinder: a brief summary. In: Software Engineering 2014, Fachtagung des GI-Fachbereichs Softwaretechnik, 25–28 Februar 2014, Kiel, Deutschland, pp. 39–40 (2014)
Gaudel, M.-C.: Testing can be formal, too. In: Mosses, P.D., Nielsen, M., Schwartzbach, M.I. (eds.) CAAP 1995. LNCS, vol. 915, pp. 82–96. Springer, Heidelberg (1995). https://doi.org/10.1007/3-540-59293-8_188
Greenaway, D., Lim, J., Andronick, J., Klein, G.: Don’t sweat the small stuff: formal verification of C code without the pain. In: ACM SIGPLAN Conference on Programming Language Design and Implementation, Edinburgh, UK, June 2014, pp. 429–439. ACM (2014)
Matichuk, D., Wenzel, M., Murray, T.: The Eisbach user manual. Isabelle Commun. (2015)
Nipkow, T.: Winskel is (almost) right: towards a mechanized semantics textbook. Formal Aspects Comput. 10, 171–186 (1998)
Working Group (WG26) of the ISO/IEC JTC1/SC7 Software and Software Engineering Committee. ISO/IEC/IEEE 29119 Software Testing: The International Standard for Software Testing (2007–2014)
Schirmer, N.: Verification of sequential imperative programs in Isabelle/HOL. Ph.D. thesis, Technische Universität München (2006)
FCAS Team et al.: What is a “decision” in application of Modified Condition/Decision Coverage (MC/DC) and Decision Coverage (DC). Technical report position paper (2002)
Torlak, E., Jackson, D.: Kodkod: a relational model finder. In: Grumberg, O., Huth, M. (eds.) TACAS 2007. LNCS, vol. 4424, pp. 632–647. Springer, Heidelberg (2007). https://doi.org/10.1007/978-3-540-71209-1_49
Williams, N., Marre, B., Mouy, P., Roger, M.: PathCrawler: automatic generation of path tests by combining static and dynamic analysis. In: Dal Cin, M., Kaâniche, M., Pataricza, A. (eds.) EDCC 2005. LNCS, vol. 3463, pp. 281–292. Springer, Heidelberg (2005). https://doi.org/10.1007/11408901_21
Winskel, G.: The Formal Semantics of Programming Languages. MIT Press, Cambridge (1993)
Acknowledgments
The author would like to thank Burkhart Wolff for setting up the foundations of this work. She also thanks the anonymous reviewers for valuable and detailed comments on how to improve the article.
Author information
Authors and Affiliations
Corresponding author
Editor information
Editors and Affiliations
Rights and permissions
Copyright information
© 2018 Springer International Publishing AG, part of Springer Nature
About this paper
Cite this paper
Keller, C. (2018). Tactic Program-Based Testing and Bounded Verification in Isabelle/HOL. In: Dubois, C., Wolff, B. (eds) Tests and Proofs. TAP 2018. Lecture Notes in Computer Science(), vol 10889. Springer, Cham. https://doi.org/10.1007/978-3-319-92994-1_6
Download citation
DOI: https://doi.org/10.1007/978-3-319-92994-1_6
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-319-92993-4
Online ISBN: 978-3-319-92994-1
eBook Packages: Computer ScienceComputer Science (R0)