mirror of
https://github.com/samsonjs/instapaper.git
synced 2026-03-25 08:55:49 +00:00
fix rubocop warnings
This commit is contained in:
parent
dab3c0d9de
commit
95a2ad91b1
2 changed files with 5 additions and 7 deletions
|
|
@ -23,9 +23,7 @@ describe Instapaper::Client::OAuth do
|
|||
end
|
||||
|
||||
it 'returns a hash containing the error on invalid credentials' do
|
||||
expect {
|
||||
client.access_token('inval1d', 'cr3dentials')
|
||||
}.to raise_error(Instapaper::Error::OAuthError)
|
||||
expect { client.access_token('inval1d', 'cr3dentials') }.to raise_error(Instapaper::Error::OAuthError)
|
||||
end
|
||||
end
|
||||
end
|
||||
|
|
|
|||
|
|
@ -21,7 +21,7 @@ describe Instapaper::Error do
|
|||
|
||||
Instapaper::Error::ERRORS.each do |status, exception|
|
||||
context "when HTTP status is #{status}" do
|
||||
let(:response_body) { %{[{"type":"error", "error_code":#{status}, "message":"Error Message URL"}]} }
|
||||
let(:response_body) { %([{"type":"error", "error_code":#{status}, "message":"Error Message URL"}]) }
|
||||
before do
|
||||
stub_post('/api/1/oauth/access_token')
|
||||
.to_return(status: 200, body: response_body, headers: {content_type: 'application/json; charset=utf-8'})
|
||||
|
|
@ -34,7 +34,7 @@ describe Instapaper::Error do
|
|||
|
||||
Instapaper::Error::BOOKMARK_ERRORS.each do |status, exception|
|
||||
context "when HTTP status is #{status}" do
|
||||
let(:response_body) { %{[{"type":"error", "error_code":#{status}, "message":"Error Message URL"}]} }
|
||||
let(:response_body) { %([{"type":"error", "error_code":#{status}, "message":"Error Message URL"}]) }
|
||||
before do
|
||||
stub_post('/api/1/bookmarks/list')
|
||||
.to_return(status: 200, body: response_body, headers: {content_type: 'application/json; charset=utf-8'})
|
||||
|
|
@ -47,7 +47,7 @@ describe Instapaper::Error do
|
|||
|
||||
Instapaper::Error::FOLDER_ERRORS.each do |status, exception|
|
||||
context "when HTTP status is #{status}" do
|
||||
let(:response_body) { %{[{"type":"error", "error_code":#{status}, "message":"Error Message URL"}]} }
|
||||
let(:response_body) { %([{"type":"error", "error_code":#{status}, "message":"Error Message URL"}]) }
|
||||
before do
|
||||
stub_post('/api/1/folders/list')
|
||||
.to_return(status: 200, body: response_body, headers: {content_type: 'application/json; charset=utf-8'})
|
||||
|
|
@ -60,7 +60,7 @@ describe Instapaper::Error do
|
|||
|
||||
Instapaper::Error::HIGHLIGHT_ERRORS.each do |status, exception|
|
||||
context "when HTTP status is #{status}" do
|
||||
let(:response_body) { %{[{"type":"error", "error_code":#{status}, "message":"Error Message URL"}]} }
|
||||
let(:response_body) { %([{"type":"error", "error_code":#{status}, "message":"Error Message URL"}]) }
|
||||
before do
|
||||
stub_post('/api/1.1/bookmarks/123/highlights')
|
||||
.to_return(status: 200, body: response_body, headers: {content_type: 'application/json; charset=utf-8'})
|
||||
|
|
|
|||
Loading…
Reference in a new issue