Search icon
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Refactoring with C#

You're reading from  Refactoring with C#

Product type Book
Published in Nov 2023
Publisher Packt
ISBN-13 9781835089989
Pages 434 pages
Edition 1st Edition
Languages
Author (1):
Matt Eland Matt Eland
Profile icon Matt Eland

Table of Contents (24) Chapters

Preface 1. Part 1: Refactoring with C# in Visual Studio
2. Chapter 1: Technical Debt, Code Smells, and Refactoring 3. Chapter 2: Introduction to Refactoring 4. Chapter 3: Refactoring Code Flow and Iteration 5. Chapter 4: Refactoring at the Method Level 6. Chapter 5: Object-Oriented Refactoring 7. Part 2: Refactoring Safely
8. Chapter 6: Unit Testing 9. Chapter 7: Test-Driven Development 10. Chapter 8: Avoiding Code Anti-Patterns with SOLID 11. Chapter 9: Advanced Unit Testing 12. Chapter 10: Defensive Coding Techniques 13. Part 3: Advanced Refactoring with AI and Code Analysis
14. Chapter 11: AI-Assisted Refactoring with GitHub Copilot 15. Chapter 12: Code Analysis in Visual Studio 16. Chapter 13: Creating a Roslyn Analyzer 17. Chapter 14: Refactoring Code with Roslyn Analyzers 18. Part 4: Refactoring in the Enterprise
19. Chapter 15: Communicating Technical Debt 20. Chapter 16: Adopting Code Standards 21. Chapter 17: Agile Refactoring 22. Index 23. Other Books You May Enjoy

Understanding technical debt and legacy code

While computer science education, books, tutorials, and online courses all focus on creating new projects from scratch, the reality is that almost all development jobs you’ll have will center around understanding, maintaining, and expanding pre-existing code that may not meet your current standards.

This pre-existing code is referred to as legacy code. You almost always inherit some amount of legacy code when joining a new project. This can be a large amount of code for pre-existing projects or a smaller set of libraries your code must work with.

There are many different definitions of the term legacy code. One that stands out to me from my readings is Michael C. Feather’s definition, in Working Effectively with Legacy Code, that legacy code is code without tests.

While I like Michael’s definition and believe testing is critically important, as we’ll see in Part 2 of this book, I personally define legacy...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at €14.99/month. Cancel anytime}