* ICSE 2018 *
Sun 27 May - Sun 3 June 2018 Gothenburg, Sweden
Fri 1 Jun 2018 14:00 - 14:20 at J1 room - Search-Based Software Engineering II Chair(s): Daniel Varro

Database-centric systems strongly rely on SQL queries to manage and manipulate their data. These SQL commands can range from very simple selections to queries that involve several tables, subqueries, and grouping operations. And, as with any important piece of code, developers should properly test SQL queries. In order to completely test a SQL query, developers need to create test data that exercise all possible coverage targets in a query, e.g., JOINs and WHERE predicates. And indeed, this task can be challenging and time-consuming for complex queries. Previous studies have modeled the problem of generating test data as a constraint satisfaction problem and, with the help of SAT solvers, generate the required data. However, such approaches have strong limitations, such as partial support for queries with JOINs, subqueries, and strings (which are commonly used in SQL queries). In this paper, we model test data generation for SQL queries as a search-based problem. Then, we devise and evaluate three different approaches based on random search, biased random search, and genetic algorithms (GAs). The GA, in particular, uses a fitness function based on information extracted from the physical query plan of a database engine as search guidance. We then evaluate each approach in 2,135 queries extracted from three open source software and one industrial software system. Our results show that GA is able to completely cover 98.6% of all queries in the dataset, requiring only a few seconds for each query. Moreover, it does not suffer from the limitations affecting state-of-the art techniques.

Fri 1 Jun

icse-2018-Technical-Papers
14:00 - 15:30: Technical Papers - Search-Based Software Engineering II at J1 room
Chair(s): Daniel VarroMcGill University / Budapest University of Technology and Economics
icse-2018-Technical-Papers152785440000014:00 - 14:20
Talk
Jeroen Castelein, Mauricio AnicheDelft University of Technology, Netherlands, Mozhan Soltani, Annibale PanichellaDeflt University of Technology, Arie van DeursenDelft University of Technology
DOI Pre-print Media Attached
icse-2018-Technical-Papers152785560000014:20 - 14:40
Talk
DOI Pre-print Media Attached
icse-2018-Journal-first-papers152785680000014:40 - 15:00
Talk
Hong Lu, Shuai Wang, Tao YueSimula Research Laboratory and University of Oslo, Shaukat AliSimula Research Lab, Jan Nygard
icse-2018-Technical-Papers152785800000015:00 - 15:20
Talk
Sooyoung ChaKorea University, South Korea, Seongjoon Hong, Junhee Lee, Hakjoo OhKorea University
Pre-print
icse-2018-Technical-Papers152785920000015:20 - 15:30
Talk