Logic Programming

Volume 5366 of the series Lecture Notes in Computer Science pp 754-758

A Constraint Logic Programming Approach to Automated Testing

  • Hakim BelhaouariAffiliated withLaboratoire d’Informatique de Paris 6, UPMC Paris Universitas
  • , Frédéric PeschanskiAffiliated withLaboratoire d’Informatique de Paris 6, UPMC Paris Universitas

* Final gross prices may vary according to local VAT.

Get Access


In this paper we present a new constraint solver for the automated generation of test cases from specifications. The specification language is inspired by the contract-oriented programming extended with a finite state machines. Beyond the generation of correct argument values for method calls, we generate full test scenarios thanks to the symbolic animation of the specifications. We propose a flexible CSP architecture that can operate not only on integer or bounded domains but also on arbitrary types. An original notion of type builder is used to establish the link between the type semantics and the CSP framework. We illustrate this with a string builder that can automatically generate string instances depending on combinations of constraints.