Best Resources for Learning TDD with Rails

I finally got a handle on the rails and felt comfortable enough with it to start learning the best practices, the first on my list being TDD principles. What are the best resources for learning TDD with Rails? Books, textbooks, whatever. I am hungry to study!

+1
ruby ruby-on-rails tdd
Jun 14 '11 at 18:38
source share
4 answers

If you want to buy a book, I suggest you familiarize yourself with the pragmatic recommendations for checking rails . It is not stuck in the implementation, as the rspec book is and will most likely allow you to choose the tools you want.

I feel it’s better to read this book than millions of posts where pro / con BDD / TDD rotates;)

+6
Jun 14 '11 at 19:00
source share
+4
Jun 14 '11 at 18:47
source share

My usual Rails and learning answer usually ends with Railscasts . Check out the section. Although TDD is not specific, most of them relate to the subject. Especially cucumbers, etc.

+3
Jun 14 '11 at 18:48
source share

I would advise you to focus on the basics here! Do not fall in love with any particular way to do TDD, such as rspec, shoulda or the like. Wait with this part until you understand the basics of TDD rails - THEN you can go out and add testing tools to your toolbox.

Start by writing a simple test for some part of your application where the logic does something other than CRUD work, in some place where you are processing some math or strange user behavior and trying to write a test for this case - but make sure that you have time for this, because for the first time it will take much more time than expected.

Once you have this test case and work, and you fully understand why, then you are ready to expand and start playing with all the great testing tools out there.

+2
Jun 14 '11 at 20:12
source share



All Articles