Skip to content

Instantly share code, notes, and snippets.

@jakehow
Created August 4, 2013 20:06
Show Gist options
  • Save jakehow/6151726 to your computer and use it in GitHub Desktop.
Save jakehow/6151726 to your computer and use it in GitHub Desktop.
Working No Doc example spec
require 'rspec_api_documentation'
require 'rspec_api_documentation/dsl'
require 'spec_helper'
resource 'No_Doc Test' do
get "/foo" do
example "should appear in docs" do
do_request
status.should == 200
end
example "should appear in docs, but NOT show the request" do
# When you need to make a preliminary request to setup your test.
no_doc do
do_request
status.should == 200
end
# put the request you actually want to document here.
end
example "should NOT appear AT ALL", :document => false do
do_request
status.should == 200
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment