An Empirical Exploration of Refactoring effect on Software Quality using External Quality Factors

Sandeepa Harshanganie Kannangara, Janaka Wijayanayake


Quality software are robust, reliable and easy to maintain, and therefore reduces the cost of software maintenance. Since software systems undergo modifications, improvements and enhancements to cope with evolving requirements, quality of software can be decreased. While software system is evolving, Refactoring is one of the methods which have been applied with the purpose of improving the software quality. Refactoring is defined as the process of improving the design of the existing code by changing its internal structure without affecting its external behavior, with the main aims of improving the quality of software product. Therefore, there is belief that refactoring improves quality factors such as understandability, flexibility, and reusability. However, there is limited empirical evidence to support such assumptions.
The objective of this study is to validate/invalidate the claims that refactoring improves software quality. Experimental research approach was used to achieve the objective and ten selected refactoring techniques were used for the analysis. The overall impact of selected refactoring techniques and the impact of individual refactoring technique was assessed based on external measures namely; analyzability, changeability, time behavior and resource utilization.
After analyzing the experimental results, overall analysis ended up with the result that refactoring deteriorate the code quality. However, individual analysis shows that some refactoring techniques improve the code quality while rest is deteriorating the code quality. Furthermore, among the tested ten refactoring techniques, “Replace Conditional with Polymorphism” ranked in the highest as having high percentage of improvement in code quality and “Introduce Null Object” was ranked as worst which is having highest percentage of deteriorate of code quality among the analyzed ten refactoring techniques.


Refactoring; Software Maintenance; Analyzability; Changeability; Time Behavior; Resource Utilization; ISO 9126

Full Text:


Printing Sponsor
University of Colombo
School of Computing

Managed & Published

Creative Commons License
This journal is published under a Creative Commons Attribution 4.0 International License.