Takeaways
Testing is the best way to maintain application performance after optimization. Let’s summarize what it takes to do that.
-
Write performance tests—special kinds of integration tests that benchmark your code, keep results, and then assert performance by comparing current and previous benchmarks.
-
Make sure your performance tests get the measurements and comparisons right. Use the framework we wrote in this chapter to create your own performance tests.
-
When performance testing Rails, don’t forget about database performance. Make sure you create enough data for performance tests, and check how many queries your requests run.
Congratulations! Now you know everything you need to know to optimize your Ruby code, measure optimization ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Read now
Unlock full access