Navigation auf zora.uzh.ch

Search ZORA

ZORA (Zurich Open Repository and Archive)

Scented Since the Beginning: On the Diffuseness of Test Smells in Automatically Generated Test Code

Grano, Giovanni; Palomba, Fabio; Di Nucci, Dario; De Lucia, Andrea; Gall, Harald C (2019). Scented Since the Beginning: On the Diffuseness of Test Smells in Automatically Generated Test Code. Journal of Systems and Software, 156:312-327.

Abstract

Software testing represents a key software engineering practice to ensure source code quality and reliability. To support developers in this activity and reduce testing effort, several automated unit test generation tools have been proposed. Most of these approaches have the main goal of covering as more branches as possible. While these approaches have good performance, little is still known on the maintainability of the test code they produce, i.e., whether the generated tests have a good code quality and if they do not possibly introduce issues threatening their effectiveness. To bridge this gap, in this paper we study to what extent existing automated test case generation tools produce potentially problematic test code. We consider seven test smells, i.e., suboptimal design choices applied by programmers during the development of test cases, as measure of code quality of the generated tests, and evaluate their diffuseness in the unit test classes automatically generated by three state-of-the-art tools such as Randoop, JTExpert, and Evosuite. Moreover, we investigate whether there are characteristics of test and production code influencing the generation of smelly tests. Our study shows that all the considered tools tend to generate a high quantity of two specific test smell types, i.e., Assertion Roulette and Eager Test, which are those that previous studies showed to negatively impact the reliability of production code. We also discover that test size is correlated with the generation of smelly tests. Based on our findings, we argue that more effective automated generation algorithms that explicitly take into account test code quality should be further investigated and devised.

Additional indexing

Item Type:Journal Article, refereed, original work
Communities & Collections:03 Faculty of Economics > Department of Informatics
Dewey Decimal Classification:000 Computer science, knowledge & systems
Scopus Subject Areas:Physical Sciences > Software
Physical Sciences > Information Systems
Physical Sciences > Hardware and Architecture
Scope:Discipline-based scholarship (basic research)
Language:English
Date:2019
Deposited On:31 Jul 2019 13:46
Last Modified:01 Dec 2024 04:41
Publisher:Elsevier
ISSN:0164-1212
OA Status:Green
Publisher DOI:https://doi.org/10.1016/j.jss.2019.07.016
Other Identification Number:merlin-id:17925
Download PDF  'Scented Since the Beginning: On the Diffuseness of Test Smells in Automatically Generated Test Code'.
Preview
  • Content: Published Version
  • Licence: Creative Commons: Attribution-NonCommercial-NoDerivatives 4.0 International (CC BY-NC-ND 4.0)

Metadata Export

Statistics

Citations

Dimensions.ai Metrics
29 citations in Web of Science®
35 citations in Scopus®
Google Scholar™

Altmetrics

Downloads

250 downloads since deposited on 31 Jul 2019
29 downloads since 12 months
Detailed statistics

Authors, Affiliations, Collaborations

Similar Publications