Created
December 7, 2009 06:25
-
-
Save evolve2k/250666 to your computer and use it in GitHub Desktop.
This file contains 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
class TwatsController < ApplicationController | |
def new | |
@twat = Twat.new | |
end | |
end | |
require 'spec_helper' | |
describe TwatsController do | |
describe "#new" do | |
it "instantiate a new twat" do | |
twat = mock('My first Twat') | |
Twat.should_receive(:new).and_return(twat) | |
get :new | |
end | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment