An empirical analysis of the distribution of unit test smells and their impact on software maintenance
- 1 September 2012
- conference paper
- Published by Institute of Electrical and Electronics Engineers (IEEE)
- No. 10636773,p. 56-65
Abstract
Unit testing represents a key activity in software development and maintenance. Test suites with high internal quality facilitate maintenance activities, such as code comprehension and regression testing. Several guidelines have been proposed to help developers write good test suites. Unfortunately, such rules are not always followed resulting in the presence of bad test code smells (or simply test smells). Test smells have been defined as poorly designed tests and their presence may negatively affect the maintainability of test suites and production code. Despite the many studies that address code smells in general, until now there has been no empirical evidence regarding test smells (i) distribution in software systems nor (ii) their impact on the maintainability of software systems. This paper fills this gap by presenting two empirical studies. The first study is an exploratory analysis of 18 software systems (two industrial and 16 open source) aimed at analyzing the distribution of test smells in source code. The second study, a controlled experiment involving twenty master students, is aimed at analyzing whether the presence of test smells affects the comprehension of source code during software maintenance. The results show that (i) test smells are widely spread throughout the software systems studied and (ii) most of the test smells have a strong negative impact on the comprehensibility of test suites and production code.Keywords
This publication has 12 references indexed in Scilit:
- An exploratory study of the impact of antipatterns on class change- and fault-pronenessEmpirical Software Engineering, 2011
- An Empirical Study of the Impact of Two Antipatterns, Blob and Spaghetti Code, on Program Comprehension2011
- How Developers' Experience and Ability Influence Web Application Comprehension Tasks Supported by UML Stereotypes: A Series of Four ExperimentsIEEE Transactions on Software Engineering, 2009
- On The Detection of Test Smells: A Metrics-Based Approach for General Fixture and Eager TestIEEE Transactions on Software Engineering, 2007
- Rule-based Assessment of Test Quality.The Journal of Object Technology, 2007
- Evaluating the effect of a delegated versus centralized control style on the maintainability of object-oriented softwareIEEE Transactions on Software Engineering, 2004
- An experiment investigating the effect of information hiding on maintainability2002
- Recovering traceability links between code and documentationIEEE Transactions on Software Engineering, 2002
- Experimentation in Software Engineering2000
- Maintaining object-oriented softwareIEEE Software, 1993