skip to main content
research-article

Test code differencing for test-driven refactoring automation

Published:31 January 2009Publication History
Skip Abstract Section

Abstract

Test-driven refactoring (TDR) requires the developer to finish test adaptation before applying refactoring. However, the current approaches of TDR usually compromise the principle of Test-First and make the refactoring intent implicit. The failed delivery of refactoring intent hinders the opportunity of test-driven refactoring automation (TDRA). In this paper, a test code differencing algorithm TestDiff is provided to extract refactoring intents from test adaptation. A tool, Refiner, is demonstrated and evaluated by real cases.

References

  1. George W. Adamson and Jillian Boreham. The Use of an Association Measure based on Character Structure to Identify Semantically Related Pairs of Words and Document Titles. Information Storage and Retrieval, 10(7-8):253--260, July-August 1974.Google ScholarGoogle ScholarCross RefCross Ref
  2. Kent Beck. Test-Driven Development: By Example. Addison-Wesley, 2002. Google ScholarGoogle ScholarDigital LibraryDigital Library
  3. Danny Dig, Can Comertoglu, Darko Marinov, and Ralph Johnson. Automated Detection of Refactorings in Evolving Components. In Proceedings of European Conference on Object-Oriented Programming, pages 404--428, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  4. Barthélémy Dagenais and Martin P. Robillard. Recommending Adaptive Changes for Framework Evolution. In Proceedings of the 30th International Conference on Software Engineering, pages 481--490, May 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  5. Martin Fowler, Kent Beck, John Brant, William Opdyke, and Don Roberts. Refactoring: Improving the Design of Existing Code. Addison-Wesley, 1999. Google ScholarGoogle ScholarDigital LibraryDigital Library
  6. Johannes Henkel and Amer Diwan. CatchUp!: Capturing and Replaying Refactorings to Support API Evolution. In Proceedings of the 27th International Conference on Software Engineering, pages 274--283, 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  7. David Janzen and Hossein Saiedian. Test-Driven Development: Concepts, Taxonomy, and Future Direction. IEEE Computer, 38(9):43--50, September 2005. Google ScholarGoogle ScholarDigital LibraryDigital Library
  8. Lee Wei Mar, Jinghong Cox Chen, and Hewijin Christine Jiau. Previewing the Effects of Refactoring. VDM Verlag Dr. Müller Aktiengesellschaft & Co. KG, 2008.Google ScholarGoogle Scholar
  9. Tom Mens and Tom Tourwé. A Survey of Software Refactoring. IEEE Transactions on Software Engineering, 30(2):126--139, February 2004. Google ScholarGoogle ScholarDigital LibraryDigital Library
  10. Jens Uwe Pipka. Refactoring in a 'Test First' -- World. In Proceedings of The Third International Conference on eXtreme Programming and Flexible Processes in Software Engineering, pages 178--181, 2002.Google ScholarGoogle Scholar
  11. Romain Robbes. Mining a Change-Based Software Repository. In Proceedings of the Fourth International Workshop on Mining Software Repositories, pages 15--15, May 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  12. Thorsten Shäfer, Jan Jonas, and Mira Mazini. Mining Framework Usage Changes from Instantiation Code. In Proceedings of the 30th International Conference on Software Engineering, pages 471--480, May 2008. Google ScholarGoogle ScholarDigital LibraryDigital Library
  13. Kunal Taneja, Danny Dig, and Tao Xie. Automated Detection of API Refactorings in Libraries. In Proceedings of the Twenty-Second IEEE/ACM International Conference on Automated Software Engineering, pages 377--380, November 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library
  14. Arie van Deursen and Leon Moonen. The Video Store Revisited - Thoughts on Refactoring and Testing. In Proceedings of the 3nd International Conference on Extreme Programming and Flexible Processes in Software Engineering (XP2002), pages 71--76, May 2002.Google ScholarGoogle Scholar
  15. Mathieu Verbaere, Ran Ettinger, and Oege de Moor. JunGL: a Scripting Language for Refactoring. In Proceedings of the 28th International Conference on Software Engineering, pages 172--181, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  16. Peter Weißgerber and Stephan Diehl. Identifying Refactorings from Source-Code Changes. In Proceedings of the 21th IEEE/ACM International Conference on Automated Software Engineering, pages 231--240, 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  17. Zhenchang Xing and Eleni Stroulia. Refactoring Detection based on UMLDiff Change-Facts Queries. In Proceedings of the 13th Working Conference on Reverse Engineering, pages 263--274, October 2006. Google ScholarGoogle ScholarDigital LibraryDigital Library
  18. Zhenchang Xing and Eleni Stroulia. APIEvolution Support with Diff-CatchUp. IEEE Transactions on Software Engineering, 33(12):818--836, December 2007. Google ScholarGoogle ScholarDigital LibraryDigital Library

Index Terms

  1. Test code differencing for test-driven refactoring automation

            Recommendations

            Comments

            Login options

            Check if you have access through your login credentials or your institution to get full access on this article.

            Sign in

            Full Access

            • Published in

              cover image ACM SIGSOFT Software Engineering Notes
              ACM SIGSOFT Software Engineering Notes  Volume 34, Issue 1
              January 2009
              119 pages
              ISSN:0163-5948
              DOI:10.1145/1457516
              Issue’s Table of Contents

              Copyright © 2009 Authors

              Publisher

              Association for Computing Machinery

              New York, NY, United States

              Publication History

              • Published: 31 January 2009

              Check for updates

              Qualifiers

              • research-article

            PDF Format

            View or Download as a PDF file.

            PDF

            eReader

            View online with eReader.

            eReader