Writing Solid Ruby Code
summary
Argues that the single best way to raise confidence is repeatable tests and shows concrete tactics: run mutation testing with Heckle to find weak specs, fuzz external inputs, and treat tests as readable specifications; use interactive exploration with pry and the Ruby debugger to inspect state during failures; measure cyclomatic complexity to find the 79+ hot methods; fortify controllers by scoping DB/URL-derived queries to current_user; and ship a tiny helper, readable specs using rspec-given, for clearer examples like the Gilded Rose kata.
AI-written summary · about
chapters (16)
- 0:00Start
- 0:25Disclaimer
- 0:52Writing Solid Ruby Code
- 1:39How Confident Are You in the Code
- 2:55Donald Knuth
- 5:51Elements of Programming Style
- 6:08Software Tools
- 8:55Object Orion
- 10:19Refactoring and Extreme Programming
- 10:47Writing Solid Code
- 14:36Assert Yourself
- 20:29Mutation Testing Fuzz Testing
- 21:26Testing Advice
- 33:20Candy Machine Interfaces
- 35:10Realloc
- 44:35Nested Conditional Operators
related talks
20mMake it SPECtacular
32mruby best practice patterns
01h 12mRuby Best Practice Patterns
37mHow to Write Better Code Using Mutation Testing
23mMental Models for Better Code
20mApplying RSpec Best Practices
35mThe worst Ruby codes I've seen in my life
41mWhat Developing With Ruby Can Teach Us About Developing Ruby
