m35pwa
Last Updated: February 25, 2016
·
4.154K
· errm
3ab480f83c76db55c2fbbf1168da2e16

render :nothing => true

Spec it like this:

describe "#show" do
  it "renders nothing"
    get :show
    response.body.should be_blank
  end
end

In the controller:

def show
  render :nothing => true
end
Say Thanks
Respond

1 Response
Add your response

22563
None
expect(response.body).to be_blank
over 1 year ago ·