From e04b52028d198437fc5aca57ae6563ba327a57c8 Mon Sep 17 00:00:00 2001 From: Max Brunsfeld and Patrick Bozeman Date: Mon, 11 Feb 2013 20:12:40 +0000 Subject: [PATCH] fix file range tests Change-Id: I7cab0b74b8189c35b806dc263b4aa8161c4a71ca --- spec/simple/file_range/ruby_sinatra_spec.rb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/spec/simple/file_range/ruby_sinatra_spec.rb b/spec/simple/file_range/ruby_sinatra_spec.rb index 267af4f..c8c1ef7 100644 --- a/spec/simple/file_range/ruby_sinatra_spec.rb +++ b/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