Minor cleanup on tests

This commit is contained in:
Steven Bazyl 2013-05-31 15:39:16 -07:00
parent 664e21290a
commit 35c38a1ce8
2 changed files with 3 additions and 6 deletions

View File

@ -218,10 +218,7 @@ describe Google::APIClient do
it 'should generate valid requests when multivalued parameters are passed' do
conn = stub_connection do |stub|
stub.post('/prediction/v1.2/training?data=1&data=2') do |env|
# Test is now passing with Faraday 0.9.0.rc1, but small bug in test adapter
#params = env[:params]
params = Faraday::FlatParamsEncoder.decode(env.url.query)
params['data'].should include('1', '2')
env.params['data'].should include('1', '2')
end
end
request = CLIENT.execute(

View File

@ -36,7 +36,7 @@ shared_examples_for 'configurable user agent' do
it 'should not allow the user agent to be used with bogus values' do
(lambda do
client.user_agent = 42
client.execute(:uri=>'http://www.google.com/')
client.execute(:uri=>'https://www.google.com/')
end).should raise_error(TypeError)
end
@ -51,7 +51,7 @@ shared_examples_for 'configurable user agent' do
[200, {}, ['']]
end
end
client.execute(:uri=>'http://www.google.com/', :connection => conn)
client.execute(:uri=>'https://www.google.com/', :connection => conn)
conn.verify
end
end