Skip to content

Instantly share code, notes, and snippets.

@simplyb
Created September 24, 2012 02:54
Show Gist options
  • Save simplyb/3773941 to your computer and use it in GitHub Desktop.
Save simplyb/3773941 to your computer and use it in GitHub Desktop.
require 'performance_helper'
require 'benchmark'
describe UsersController, :type => :controller do
context "index performance" do
it 'should be fast' do
Benchmark.realtime{
get :index, :format => :json
}.should < 0.5
end
end
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment