Skip to content

Commit

Permalink
Update tests, temporarily disable ones hitting dead URLs
Browse files Browse the repository at this point in the history
  • Loading branch information
sqrrrl committed Nov 6, 2015
1 parent 601c251 commit c3b0702
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
9 changes: 6 additions & 3 deletions spec/signet/oauth_1/services/google_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -95,14 +95,16 @@ def merge_body(chunked_body)
end

it 'should raise an error if the token credentials are bogus' do
expect(lambda do
expect do
skip 'Need to replace with mocked response as google endpoints no longer use oauth1'
@client.token_credential_key = '12345'
@client.token_credential_secret = '12345'
@client.fetch_protected_resource(
res = @client.fetch_protected_resource(
:uri =>
'https://www.google.com/m8/feeds/'
)
end).to raise_error(Signet::AuthorizationError)
puts "Res = #{res.status}"
end.to raise_error(Signet::AuthorizationError)
end

# We have to stub responses for the token credentials
Expand Down Expand Up @@ -228,6 +230,7 @@ def merge_body(chunked_body)
end

it 'should raise an error if the client credentials are bogus' do
skip 'Need to replace with mocked response as google endpoints no longer use oauth1'
expect(lambda do
@client.fetch_protected_resource(
:uri =>
Expand Down
2 changes: 1 addition & 1 deletion spec/signet/oauth_2/client_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -889,7 +889,7 @@ def build_form_encoded_response(payload)
-----END PUBLIC KEY-----
PUBKEY
@client.decoded_id_token(pubkey)
end).to raise_error(JWT::DecodeError, "Signature verification failed")
end).to raise_error(JWT::VerificationError)
stubs.verify_stubbed_calls
end
end
Expand Down

0 comments on commit c3b0702

Please sign in to comment.