Acceptance Tests with RSpec and Capybara

by Charles Max Wood on May 23, 2011

On the Ruby Rogues podcast I mentioned that I had moved away from Cucumber to RSpec and Capybara for my integration tests. Here’s a demo on how to do some TDD with RSpec and Capybara.

Download 180.6 MB
Download iPhone & iPod 109.2 MB

  • http://twitter.com/rramsden Richard Ramsden

    @charles have you tried the commant-t plugin for vim? http://www.vim.org/scripts/script.php?script_id=3025

    • http://teachmetocode.com Charles Max Wood

      I’ve had about 3 people show me the cool stuff with Janus and cmd-t. Pretty happy with it. 

  • http://twitter.com/humpaaa Aljoscha M. Everding

    Command-T is bundled with Janus. But I prefer peepopen by Geoffrey Grosenbach, which is really awesome http://peepcode.com/products/peepopen

    • http://teachmetocode.com Charles Max Wood

      I’m playing with the Janus part right now. Jeff Schoolcraft actually did a quick screenshare to educate me. 

  • Loïc

    Hello.

    Great screencast!

    By the way, command-t http://www.vim.org/scripts/script.php?script_id=3025 vim plugin is bundled with Janus. So command-t should work almost as in textmate.

    From the Janus README :
    “”"
    Command-T

    Command-T provides a mechanism for searching for a file inside the
    current working directory. It behaves similarly to command-t in
    Textmate.

    Customizations: Janus rebinds command-t () to bring up this
    plugin. It defaults to t.
    “”"

    • http://teachmetocode.com Charles Max Wood

      Thanks for letting me know. 

      for those new to VIM the leader key is defined in your .vimrc file. By default, it’s the /-key, but most people change it to the ,-key or ;-key.

  • Daniel Passos

    Please. Post download links

    • http://teachmetocode.com Charles Max Wood

      Download links posted. I should have the iTunes feed fixed soon.

  • Jim Wharton

    Oh my heck! You’re in Utah??? A co-worker and I were just discussing BDD today and I said, there HAS to be someone locally that can mentor us more about METHODOLOGY instead of actual code. We haven’t tried the local RUGs yet, but if you have ANY sort of time, let me know…. jamesawharton – at – gmail – com.

    • http://teachmetocode.com Charles Max Wood

      I’m in Utah, but I love helping people. If anyone wants to do a screen sharing session, I’m open to that too. Just email me (chuck@teachmetocode.com)

  • http://mohamedaslam.com Aslam

    Try this http://peepcode.com/products/peepopen
    it’s really awesome!

  • Matthew Keene

    Does anybody else find those MacVim files really hard to read?  In the default screen size and resolution they’re just a dark mess and even when I increase to full HD and full screen mode I find them only barely readable, particularly the grey comments on the dark background.  Is there any way you can use a different color scheme which is more readable?

  • http://www.kensodev.com Avi Tzurel

    Charles, if you use Spork and autotest, you can run the specs each time you save any file that has a test.

    for example user.rb => user_spec.rb (once you save any of these will run the specs, and eventually run the entire suit).
    You are using Rails3 which load significantly slower then rails2, this will save you lots of time when you code.

  • Pravesh Singh

    Very informative post. Its really helpful for me and beginner too. Check out this link too its also having a nice post with wonderful explanation on acceptance testing…
    http://mindstick.com/Articles/119f3758-54a0-4a33-94f4-6c6fa3a62b5c/?Acceptance%20Testing

    Thanks

  • http://www.facebook.com/profile.php?id=100003791938080 James Anderson

    https://github.com/kien/ctrlp.vim is the vim plugin you’re looking for.

Previous post:

Next post: