Talks
Speakers
Events
Topics
Sign in
Home
Talks
Speakers
Events
Topics
Leaderboard
Use
Analytics
Sign in
Suggest modification to this talk
Title
Description
Good tests are isolated, they're repeatable, they're deterministic. Good tests don't touch the network and are flexible when it comes to change. Bad tests are all of the above and more. Bad tests are no tests at all: which is where I found myself with a 5 year legacy codebase running in production and touching millions of customers with minimal use-case documentation. We'll cover this experience and several like it while digging into how to go from zero to total test coverage as painlessly as possible. You will learn how to stay sane in the face of insane testing conditions, and how to use these tests to deconstruct a monolith app. When life gives you a big ball of mud, write a big ball of tests.
Date
Summarized using AI?
If this talk's summary was generated by AI, please check this box. A "Summarized using AI" badge will be displayed in the summary tab to indicate that the summary was generated using AI.
Show "Summarized using AI" badge on summary page
Summary
Markdown supported
In this talk, Richard Schneeman, a Ruby developer at Heroku, addresses the challenges of testing legacy code in a world where good tests are crucial for software reliability and maintainability. The main topics discussed in the video revolve around how to achieve total test coverage for a large legacy codebase, the techniques used for effective testing, and methods to manage the complexity of modern applications. Key points include: - **Good Testing Principles**: Good tests should be isolated, repeatable, deterministic, and not touch the network whenever possible. This contrasts sharply with bad tests, which can lead to unreliable software. - **Legacy Code and Testing Challenges**: Schneeman shares his experience of working on a legacy codebase at Heroku, which initially had zero automated tests. He emphasizes the difficulties faced while dealing with a system that impacted millions of users with minimal documentation. - **Minimum Viable Patch (MVP)**: The concept of MVPs is discussed as quick patches that can lead to technical debt if not managed properly, with testing seen as a vital step in maintaining code integrity. - **Testing Techniques**: He highlights methods such as black-box testing, using the library Hatchet to facilitate testing by deploying Heroku apps as part of the testing process, and employing strategies to retry failed tests using a gem called ReRetry. - **Integration Testing**: Integration tests are highly recommended as a way to uncover potential pain points in the code, supported by anecdotal evidence from his previous experience at Gowalla, where a critical user sign-up process failure revealed the importance of extensive testing. - **Improving Testing Efficiency**: Through various optimizations—including the use of threading for faster execution and the transition to simpler tests—the testing cycle at Heroku was dramatically improved, allowing for faster feedback and code deployment. - **Code Maintainability**: The talk concludes with a call to maintainability, encouraging attendees to cover edge cases in their tests and avoid the pitfalls of MVPs. Schneeman emphasizes that there are no untestable applications; the key is to start with integration tests and build from there. Ultimately, Schneeman advocates for building robust testing frameworks as essential components of modern software development while encouraging developers to adopt proactive testing strategies for better application performance and user satisfaction.
Suggest modifications
Cancel