O'Reilly logo

Test-Driven Java Development - Second Edition by Viktor Farcic, Alex Garcia

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Refactoring Legacy Code – Making It Young Again

TDD may not adjust to legacy code straight away. You may have to fiddle a bit with the steps to make it work. Understand that your TDD may change in this case, because somehow, you are no longer performing the TDD you were used to. This chapter will introduce you to the world of legacy code, taking as much as we can from TDD. 

We'll start afresh, with a legacy application that is currently in production. We'll alter it in small ways without introducing defects or regressions, and we'll even have time to have an early lunch!

The following topics are covered in this chapter:

  • Legacy code
  • Dealing with legacy code
  • REST communication
  • Dependency injection
  • Tests at different levels: end-to-end, integration, ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required