Refactoring In Legacy Code

Refactoring is a set of skills. We use refactoring on code and tests, to make sure we will be able to maintain our code and change it quickly the next time we need to change it. While it is easy to do with tests, it is harder (but even more essential) to do with legacy code.

In this 1/2-day workshop, we’ll try our hands in different techniques of refactoring. We’ll discuss naming methods, code extraction, practice refactoring before and after tests, and understand how to refactor legacy code to make it more testable. The objective is to learn the principles of simple design and apply them through refactoring for better code.

This is an medium level hands-on workshop. It is intended for developers with basic unit testing experience.

After this workshop you will be able to:

  • Make changes safely to existing complex code
  • Prepare your existing legacy code for unit testing
  • Refactor for better design with the aid of tests

Workshop outline:

  • Refactoring with tests – Code smells deodorant
  • Refactoring with comparison tools
  • Refactoring as preparation for tests

Target audience: This workshop is for developers with some unit testing experience who want to enhance their skills. Attendees need to bring a laptop with their favorite IDE in their favorite language (it doesn’t matter which one), and a testing framework.