The Must Read book for any software engineer. Because most of the code that we deal with is in fact legacy code.
Are you not convinced? How about these questions:
- Is the code easy to change?
- Can you get nearly instantaneous feedback when you do change it?
- Do you understand it?
If you answered any if these questions with “no”, then you are dealing with legacy code. And this is where this book comes in–it teaches strategies to deal with large, untested legacy code bases.
Working Effectively with Legacy Code teaches you to:
- Understand the motivations behind code changes: adding features, fixing bugs, improving the design, and optimising performance.
- Getting the code under control using unit tests.
- Using tests to prevent introducing new bugs.
- Detecting where to introduce changes.
- Dealing with applications that seem to have no structure–the dreaded “spaghetti code”.
The book is very practical and contains numerous code examples in Java, C++, C, and C#. But even if you don’t know these languages, you’ll be able to understand the lessons the author is teaching. The techniques can be used with any language or platform.
WordPress is essentially one big monolithic legacy application–and so are most popular plugins. Therefore getting the knowledge of how to deal with such a code base is one of the best skills you can learn.