Strong opinions, weakly held

Rails for everyone

I’m in the process of reading Agile Web Development with Rails, the introduction to Rails written by Dave Thomas and Rails creator David Heinemeier Hansson. I plan on writing a full review once I’ve finished, but I wanted to go ahead and start talking about it because both Rails and the book have prompted a lot of thinking on my part.

I’d recommend that every Web programmer read this book, even if you’re never going to install Rails, just because it will give you some ideas on how to make your own applications better. Rails does the best job of codifying the best practices for Web application development of any framework out there today, regardless of language, and once you read the book you can bring some of those practices to the platform you use and become a better programmer.

Right now I’m reading the chapter on testing Rails, and I’m just blown away by the number of ways that Rails makes it easy to test every layer of your application. The affordances provided for writing tests are comprehensive and more importantly, completely natural to the environment. The thing is, these affordances could just as easily be created in Java, it’s just that nobody has done it yet. I was impressed with the testing features of the Spring framework, but Rails takes things several steps further. I’ve written build scripts that regenerate my database schema and a unit test that stocks the database with test data. That stuff is built into Rails. As are base tests that provide the kinds of assertions you need for testing Web components and model components. You can write that stuff yourself (I have), but it’s nice to see it standardized. I’m not even going to get into the fiendishly clever test runners that are built in.

Anyway, both the book and framework are inspirational, and you don’t really need to know Ruby to get a lot out of it. If you know Perl or PHP, you can probably infer what most of the code in the book does, because truth be told, most of the examples just call various parts of the Rails framework. Check it out.

1 Comment

  1. I participated in the “beta” program for this book, mostly so that I could get at the book as soon as possible. I don’t “know” ruby (yet) but you are dead on about how this book helps you no matter what you are writing in.

Leave a Reply

Your email address will not be published.


© 2019 rc3.org

Theme by Anders NorenUp ↑