skip to main content
10.1145/2034654.2034663acmconferencesArticle/Chapter ViewAbstractPublication PagesicfpConference Proceedingsconference-collections
research-article

A PropEr integration of types and function specifications with property-based testing

Published: 23 September 2011 Publication History

Abstract

We present a tight integration of the language of types and function specifications of Erlang with property-based testing. To achieve this integration we have developed from scratch PropEr, an open-source QuickCheck-inspired property-based testing tool. We present technical details of this integration, most notably how the conversion of recursive types into appropriate generators takes place and how function specifications can be turned automatically into simple properties in order to exercise the code of these functions. Finally, we present experiences and advice for the proper use of PropEr.

Supplementary Material

MP4 File (_talk5.mp4)

References

[1]
T. Arts, J. Hughes, J. Johansson, and U. Wiger. Testing Telecoms Software with Quviq QuickCheck. In Proceedings of the 2006 ACM SIGPLAN Workshop on Erlang, pages 2--10. ACM, 2006.
[2]
R. Carlsson and M. Rémond. EUnit: A Lightweight Unit Testing Framework for Erlang. In Proceedings of the 2006 ACM SIGPLAN Workshop on Erlang, pages 1--1, New York, NY, USA, 2006. ACM.
[3]
K. Claessen and J. Hughes. QuickCheck: a Lightweight Tool for Random Testing of Haskell Programs. In Proceedings of the 5th ACM SIGPLAN International Conference on Functional Programming, pages 268--279. ACM, 2000.
[4]
EDoc. User's Guide, 2011. http://www.erlang.org/doc/apps/edoc/users_guide.html.
[5]
M. Jimenez, T. Lindahl, and K. Sagonas. A Language for Specifying Type Contracts in Erlang and its Interaction with Success Typings. In Proceedings of the 2007 SIGPLAN Workshop on Erlang, pages 11--17. ACM, 2007.
[6]
T. Lindahl and K. Sagonas. Practical Type Inference Based on Success Typings. In Proceedings of the 8th ACM SIGPLAN International Conference on Principles and Practice of Declarative Programming, pages 167--178. ACM, 2006.
[7]
PropEr. Property-based testing for Erlang, 2011. http://proper.softlab.ntua.gr/.
[8]
J. Rushby. Automated Test Generation and Verified Software. In B. Meyer and J. Woodcock, editors, Verified Software: Theories, Tools, Experiments, volume 4171 of Lecture Notes in Computer Science, pages 161--172. Springer, Berlin / Heidelberg, 2008.
[9]
K. K. Thorup. Triq: Trifork QuickCheck, 2011. http://krestenkrab.github.com/triq/.

Cited By

View all
  • (2024)Controlled Scheduling of Concurrent Elixir ProgramsProceedings of the 23rd ACM SIGPLAN International Workshop on Erlang10.1145/3677995.3678195(67-75)Online publication date: 28-Aug-2024
  • (2023)CLFuzz: Vulnerability Detection of Cryptographic Algorithm Implementation via Semantic-aware FuzzingACM Transactions on Software Engineering and Methodology10.1145/362816033:2(1-28)Online publication date: 23-Dec-2023
  • (2023)falsify: Internal Shrinking Reimagined for HaskellProceedings of the 16th ACM SIGPLAN International Haskell Symposium10.1145/3609026.3609733(97-109)Online publication date: 30-Aug-2023
  • Show More Cited By

Recommendations

Comments

Information & Contributors

Information

Published In

cover image ACM Conferences
Erlang '11: Proceedings of the 10th ACM SIGPLAN workshop on Erlang
September 2011
108 pages
ISBN:9781450308595
DOI:10.1145/2034654
Permission to make digital or hard copies of all or part of this work for personal or classroom use is granted without fee provided that copies are not made or distributed for profit or commercial advantage and that copies bear this notice and the full citation on the first page. Copyrights for components of this work owned by others than ACM must be honored. Abstracting with credit is permitted. To copy otherwise, or republish, to post on servers or to redistribute to lists, requires prior specific permission and/or a fee. Request permissions from [email protected]

Sponsors

Publisher

Association for Computing Machinery

New York, NY, United States

Publication History

Published: 23 September 2011

Permissions

Request permissions for this article.

Check for updates

Author Tags

  1. erlang
  2. function signatures
  3. property-based testing
  4. test generators
  5. type declarations

Qualifiers

  • Research-article

Conference

ICFP '11
Sponsor:

Acceptance Rates

Erlang '11 Paper Acceptance Rate 10 of 14 submissions, 71%;
Overall Acceptance Rate 51 of 68 submissions, 75%

Upcoming Conference

ICFP '25
ACM SIGPLAN International Conference on Functional Programming
October 12 - 18, 2025
Singapore , Singapore

Contributors

Other Metrics

Bibliometrics & Citations

Bibliometrics

Article Metrics

  • Downloads (Last 12 months)12
  • Downloads (Last 6 weeks)2
Reflects downloads up to 02 Mar 2025

Other Metrics

Citations

Cited By

View all
  • (2024)Controlled Scheduling of Concurrent Elixir ProgramsProceedings of the 23rd ACM SIGPLAN International Workshop on Erlang10.1145/3677995.3678195(67-75)Online publication date: 28-Aug-2024
  • (2023)CLFuzz: Vulnerability Detection of Cryptographic Algorithm Implementation via Semantic-aware FuzzingACM Transactions on Software Engineering and Methodology10.1145/362816033:2(1-28)Online publication date: 23-Dec-2023
  • (2023)falsify: Internal Shrinking Reimagined for HaskellProceedings of the 16th ACM SIGPLAN International Haskell Symposium10.1145/3609026.3609733(97-109)Online publication date: 30-Aug-2023
  • (2023)Generation and Refinement of Testing ModelsProceedings of the 22nd ACM SIGPLAN International Workshop on Erlang10.1145/3609022.3609415(14-23)Online publication date: 30-Aug-2023
  • (2023)TLS the Erlang/OTP Way (Experience Report)Proceedings of the 22nd ACM SIGPLAN International Workshop on Erlang10.1145/3609022.3609414(2-13)Online publication date: 30-Aug-2023
  • (2023)Etna: An Evaluation Platform for Property-Based Testing (Experience Report)Proceedings of the ACM on Programming Languages10.1145/36078607:ICFP(878-894)Online publication date: 31-Aug-2023
  • (2023)MUTAGEN: Reliable Coverage-Guided, Property-Based Testing using Exhaustive Mutations2023 IEEE Conference on Software Testing, Verification and Validation (ICST)10.1109/ICST57152.2023.00025(176-187)Online publication date: Apr-2023
  • (2022)Property-driven testing of black-box functionsProceedings of the IEEE/ACM 10th International Conference on Formal Methods in Software Engineering10.1145/3524482.3527657(113-123)Online publication date: 18-May-2022
  • (2022)Computing correctly with inductive relationsProceedings of the 43rd ACM SIGPLAN International Conference on Programming Language Design and Implementation10.1145/3519939.3523707(966-980)Online publication date: 9-Jun-2022
  • (2022)Metamorphic Fuzzing of C++ Libraries2022 IEEE Conference on Software Testing, Verification and Validation (ICST)10.1109/ICST53961.2022.00015(35-46)Online publication date: Apr-2022
  • Show More Cited By

View Options

Login options

View options

PDF

View or Download as a PDF file.

PDF

eReader

View online with eReader.

eReader

Figures

Tables

Media

Share

Share

Share this Publication link

Share on social media