Little by little i begin to understan开发者_JAVA百科d the power of Rspec, though i still do not see why i would need to use it to test controllers or views (i\'m sure there are reasons behind it).
Here is t开发者_运维技巧he message that I have been getting when running rspec: /home/patrick/.rvm/gems/ruby-1.9.2-p136@rails3tutorial/gems/rspec-core-2.5.1/lib/rspec/core/configuration.rb:386:in load
Trying to write a test for a helper method that uses acts_as_tree开发者_开发知识库. Helper method uses a count for children:
After generate rspec:install in a Rails 3 project any new scaffolding will include some default specs. I\'m confused about the get, post, put & delete methods and what they\'re actually being call
I\'m writing a simple comment observer which triggers a mailer whenever a new comment is created. All the relevant code is in this gist: https://gist.github.com/c3234352b3c4776ce132
I\'ve got an Rails 3 helper, which returns code depending on the params and request.headers. I\'ve tried to mock them, but didn\'t succeed. My latest try:
Controller code: class BooksController < ApplicationController def index @books = Book.all respond_to do |format|
I keep getting an issue when running RSpec with Autotest. My ~/.autotest file looks like this: require \'autotest/growl\'
Is there any existing solution (a gem preferably) to run some slices of specs with rspec? for example:
I\'ve been working through Michael Hartl\'s Rails tutorial (which is unbelievably awesome by the way).