Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')
- describe VideosController do
- before(:each) do
- @user = User.find(4)
- end
- #Delete this example and add some real ones
- it "should use VideosController" do
- controller.should be_an_instance_of(VideosController)
- end
- describe "creating a new video" do
- before(:each) do
- @video = mock_model(Video)
- Video.stub!(:new).and_return(@video)
- end
- it "should start with proper parameters" do
- current_user = @user
- get :new
- response.should_not be_success
- end
- end
- end
Add Comment
Please, Sign In to add comment