Incremental test data generation for database queries

  • María José Suárez-Cabal
  • Claudio de la Riva
  • Javier Tuya
  • Raquel Blanco
Article

DOI: 10.1007/s10515-017-0212-7

Cite this article as:
Suárez-Cabal, M.J., de la Riva, C., Tuya, J. et al. Autom Softw Eng (2017). doi:10.1007/s10515-017-0212-7
  • 58 Downloads

Abstract

Testing database applications is a complex task since it involves designing test databases with meaningful test data in order to reveal faults and, at the same time, with a small size in order to carry out the testing process in an efficient way. This paper presents an automated approach to generating test data (test relational databases and test inputs for query parameters) for a set of SQL queries, with the aim of covering test requirements as obtained from said queries. The test data generation follows an incremental approach where, in each increment, test data are generated to cover a test requirement by re-using test data previously generated for other test requirements. The test data generation for each test requirement is formulated as a constraint satisfaction problem, where constraints are derived from the test requirement, initial database states and previously generated test data. The generation process is fully automated and supports the execution on complex queries and databases. Evaluation is carried out on a real life application, and the results show that small-size generated test relational databases achieve high coverage scores for the queries under test in a short generating time.

Keywords

Software testing Database testing Test database generation Test coverage Constraint satisfaction problem (CSP) 

Copyright information

© Springer Science+Business Media New York 2017

Authors and Affiliations

  1. 1.Campus Universitario de Gijón, Dpto. InformáticaGijónSpain

Personalised recommendations