This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
require File.join(File.dirname(__FILE__), '..', 'spec_helper.rb') | |
given "logged in" do | |
login | |
end | |
describe Posts do | |
describe "index action" do | |
it "should respond correctly" do | |
dispatch_to(Posts, :index).should respond_successfully |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
it "should set new post" do | |
get('/login', :login => chucks_attributes[:login], :password => chucks_attributes[:password]) | |
Post.should_receive(:new) | |
dispatch_to(Posts, :index).should respond_successfully | |
end |
NewerOlder