Property-Based Testing requires the programmer to writesuitablegenerators, i.e., programs that generate (possibly in a randomway) input values for which the program under test should be run. How-ever, the process of writing generators is quite a costly, error-prone ac-tivity. In the context of Property-Based Testing of Erlang programs, wepropose an approach to relieve the programmer from the task of writinggenerators. Our approach allows the automatic, efficient generation ofinput test values that satisfy a given specification. In particular, we haveconsidered the case when the input values are data structures satisfy-ing complex constraints. That generation is performed via the symbolicexecution of the specification using constraint logic programming.
Property-Based Test Case Generators for Free
De Angelis E;Fioravanti F;Pettorossi A;Proietti M
2019
Abstract
Property-Based Testing requires the programmer to writesuitablegenerators, i.e., programs that generate (possibly in a randomway) input values for which the program under test should be run. How-ever, the process of writing generators is quite a costly, error-prone ac-tivity. In the context of Property-Based Testing of Erlang programs, wepropose an approach to relieve the programmer from the task of writinggenerators. Our approach allows the automatic, efficient generation ofinput test values that satisfy a given specification. In particular, we haveconsidered the case when the input values are data structures satisfy-ing complex constraints. That generation is performed via the symbolicexecution of the specification using constraint logic programming.I documenti in IRIS sono protetti da copyright e tutti i diritti sono riservati, salvo diversa indicazione.