Refactoring Process as Part of Adapting Test Tools to Real Software
摘要
Legacy code is an inherent part of industrial software projects, often resulting in complex, tightly coupled systems that challenge the integration of modern testing techniques. Unlike in academic contexts, where tools are developed with well-scoped objectives and simplified scenarios, industrial environments demand higher levels of robustness, performance, and adaptability. Refactoring, therefore, becomes a crucial process when adapting existing testing tools to support legacy code in production settings. This paper presents the refactoring of a testing tool originally developed for academic use, with the aim of making it compatible with real-world industrial C++ codebases. The project, conducted in collaboration with a naval industry partner, involved reengineering the tool’s architecture to improve readability, modularity, and execution performance. Through a case study approach, we illustrate the advantages achieved by systematically applying refactoring principles, resulting in a more robust and adaptable tool capable of supporting automated software testing in complex environments. Additionally, we provide a practical refactoring guide based on our experience, offering valuable insights for teams facing similar adaptation challenges in the future.