Skip to content

Instantly share code, notes, and snippets.

@gingerlime
Created September 18, 2012 12:16
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save gingerlime/3742800 to your computer and use it in GitHub Desktop.
Save gingerlime/3742800 to your computer and use it in GitHub Desktop.
class BlaController < ApplicationController
skip_before_filter :authenticate_user!
def index
render :nothing => true, :status => 200
end
end
require 'spec_helper'
describe BlaController do
it "should be able to puts response" do
get :index
puts response
end
end
...
200
{"Content-Type"=>"text/html; charset=utf-8"}
200
{"Content-Type"=>"text/html; charset=utf-8"}
200
{"Content-Type"=>"text/html; charset=utf-8"}
200
{"Content-Type"=>"text/html; charset=utf-8"}
200
{"Content-Type"=>"text/html; charset=utf-8"}
200
{"Content-Type"=>"text/html; charset=utf-8"}
should be able to puts response (FAILED - 1)
Failures:
1) BlaController should be able to puts response
Failure/Error: Unable to find matching line from backtrace
SystemStackError:
stack level too deep
# /usr/local/bin/ruby-1.9.3-p0/lib/ruby/gems/1.9.1/gems/activesupport-3.2.5/lib/active_support/core_ext/object/blank.rb:105
Finished in 2.54 seconds
1 example, 1 failure
Failed examples:
rspec ./spec/controllers/bla_controller_spec.rb:7 # BlaController should be able to puts response
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment