Skip to content

Commit

Permalink
Add /timeout route to fake a long response for testing RKRequest's ti…
Browse files Browse the repository at this point in the history
…meout interval. We need to leave this around 4 seconds so we don't hold up the ruby process too long and cause the tests launched after to fail.
  • Loading branch information
Brian Morton authored and blakewatters committed Jan 20, 2012
1 parent b88bba9 commit 2385814
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions Specs/Server/server.rb
Expand Up @@ -123,6 +123,15 @@ class RestKit::SpecServer < Sinatra::Base
content_type 'application/json'
params.to_json
end

get '/timeout' do
# We need to leave this around 4 seconds so we don't hold up the
# process too long and cause the tests launched after to fail.
sleep 4
status 200
content_type 'application/json'
params.to_json
end

get '/empty/array' do
status 200
Expand Down

0 comments on commit 2385814

Please sign in to comment.