ACM Home Page
Please provide us with feedback. Feedback
Testing monadic code with QuickCheck
Full text PdfPdf (136 KB)
Source Haskell archive
Proceedings of the 2002 ACM SIGPLAN workshop on Haskell table of contents
Pittsburgh, Pennsylvania
Pages: 65 - 77  
Year of Publication: 2002
ISBN:1-58113-605-6
Authors
Koen Claessen  Chalmers University of Technology
John Hughes  Chalmers University of Technology
Sponsor
SIGPLAN: ACM Special Interest Group on Programming Languages
Publisher
ACM  New York, NY, USA
Bibliometrics
Downloads (6 Weeks): 4,   Downloads (12 Months): 38,   Citation Count: 4
Additional Information:

abstract   references   cited by   collaborative colleagues  

Tools and Actions: Request Permissions Request Permissions    Review this Article  
DOI Bookmark: Use this link to bookmark this Article: http://doi.acm.org/10.1145/581690.581696
What is a DOI?

ABSTRACT

QuickCheck is a previously published random testing tool for Haskell programs. In this paper we show how to use it for testing monadic code, and in particular imperative code written using the ST monad. QuickCheck tests a program against a specification: we show that QuickCheck's specification language is sufficiently powerful to represent common forms of specifications: algebraic, model-based (both functional and relational), and pre-/post-conditional. Moreover, all these forms of specification can be used directly for testing. We define a new language of monadic properties, and make a link between program testing and the notion of observational equivalence.


REFERENCES

Note: OCR errors may be found in this Reference List extracted from the full text article. ACM has opted to expose the complete List rather than only correct and linked references.

 
1
S. Antoy and R. Hamlet. Automatically checking an implementation against its formal specification. In Irvine Software Symposium, pages 29-48, March 1992.
 
2
 
3
F. Warren Burton. An efficient functional implementation of FIFO queues. Information Processing Letters, 14(5):205-206, July 1982.
4
 
5
 
6
J. Duran and S. Ntafos. An evaluation of random testing. Transactions on Software Engineering, 10(4):438-444, July 1984.
 
7
Stephen H. Edwards. A framework for practical, automated black-box testing of component-base software. Software Testing, Verification and Reliability, 11(2), June 2001.
8
 
9
D. Hamlet. Random testing. In J. Marciniak, editor, Encyclopedia of Software Engineering, pages 970-978. Wiley, 1994.
 
10
 
11
 
12
Dean Herington. HUnit 1.0 User's Guide, 2002. http://hunit.sourceforge.net/HUnit-1.0/Guide.html.
 
13
 
14
Simon Peyton Jones. Tackling the awkward squad: monadic input/output, concurrency, exceptions, and foreign-language calls in Haskell. In Tony Hoare, Manfred Broy, and Ralf Steinbruggen, editors, Engineering theories of software construction, pages 47-96. IOS Press, 2001. Presented at the 2000 Marktoberdorf Summer School.
 
15
16
 
17
Tom Moertel. Seven Lessons from the ICFP Programming Contest. http://www.kuro5hin.org/story/2001/7/31/0102/11014, 2001.
 
18
19
20
 
21
Chris Okasaki. An Overview of Edison. In Haskell Workshop, pages 34-54, September 2000.
22
 
23
Andrew M. Pitts. Evaluation logic. In G. Birtwistle, editor, Proceedings of the IVth Higher Order Workshop, pages 162-189. Springer-Verlag, 1990.
 
24
 
25
Malcolm Wallace, Olaf Chitil, Thorsten Brehm, and Colin Runciman. Multiple-View Tracing for Haskell: a New Hat. In Haskell Workshop. ACM, September 2001.

Collaborative Colleagues:
Koen Claessen: colleagues
John Hughes: colleagues