Extending Refactoring Guidelines to Perform Client and Test Code Adaptation

(Research paper, 30 min) [ Slides ]

Author(s): Wafa Basit, Fakhar Lodhi and Usman Bhatti (National University of computer and emerging sciences, Pakistan)
Session: Refactoring
Session chair: Johannes Brodwall (Steria)
Date: Thursday, 3 June 2010: Main Conference
Time: 10:30-12:00
Refactoring is a disciplined process of applying structural transformations in the code such that the program is improved in terms of quality and its external behavior is preserved. Refactoring includes evaluation of its preconditions, execution of its mechanics and corrective actions required to retain the behavior of the program. These transformations affect various locations throughout a program which includes its clients and unit tests. Due to the complex dependencies involved within the program, preservation of program behavior often becomes nontrivial. The guidelines on refactoring by Fowler lack precision and leave opportunities for developers to err. In this paper, we analyze and present an exhaustive categorization of refactoring guidelines based on their impact on production and test code together. In addition, we present extended refactoring guidelines that adapt the clients and unit tests to keep it syntactically and semantically aligned with the refactored code.

<< Back to the program