Permalink
Browse files

fix file range tests

Change-Id: I7cab0b74b8189c35b806dc263b4aa8161c4a71ca
  • Loading branch information...
Max Brunsfeld and Patrick Bozeman authored and pbozeman committed Feb 11, 2013
1 parent 94600e2 commit e04b52028d198437fc5aca57ae6563ba327a57c8
Showing with 3 additions and 3 deletions.
  1. +3 −3 spec/simple/file_range/ruby_sinatra_spec.rb
@@ -26,7 +26,7 @@
num_bytes = 10
@file_contents = File.read("#{@app.manifest['path']}/#{FILE_NAME}")
url = "#{@session.TARGET}/apps/#{@app.name}/instances/0/files/app/#{FILE_NAME}"
- hdrs = {"AUTHORIZATION" => @session.token, "Range" => "bytes=#{range}"}
+ hdrs = {"AUTHORIZATION" => @session.token.auth_header, "Range" => "bytes=#{range}"}
resp = RestClient.get(url, hdrs)
resp.should_not == nil
@@ -43,7 +43,7 @@
num_bytes = 10
@file_contents = File.read("#{@app.manifest['path']}/#{FILE_NAME}")
url = "#{@session.TARGET}/apps/#{@app.name}/instances/0/files/app/#{FILE_NAME}"
- hdrs = {"AUTHORIZATION" => @session.token, "Range" => "bytes=#{range}"}
+ hdrs = {"AUTHORIZATION" => @session.token.auth_header, "Range" => "bytes=#{range}"}
resp = RestClient.get(url, hdrs)
resp.should_not == nil
@@ -62,7 +62,7 @@
num_bytes = fin - start + 1
@file_contents = File.read("#{@app.manifest['path']}/#{FILE_NAME}")
url = "#{@session.TARGET}/apps/#{@app.name}/instances/0/files/app/#{FILE_NAME}"
- hdrs = {"AUTHORIZATION" => @session.token, "Range" => "bytes=#{range}"}
+ hdrs = {"AUTHORIZATION" => @session.token.auth_header, "Range" => "bytes=#{range}"}
resp = RestClient.get(url, hdrs)
resp.should_not == nil

0 comments on commit e04b520

Please sign in to comment.