Skip to content

Commit 8b798fa

Browse files
author
Ron Dahlgren
committed
Update test expectations to match reformated messages
1 parent 3073549 commit 8b798fa

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

spec/serpapi/client/client_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,7 @@
7373
it 'get endpoint error' do
7474
expect {
7575
client.send(:get, '/search', :json, {})
76-
}.to raise_error(SerpApi::SerpApiError).with_message(/HTTP request failed with error: Missing query `q` parameter./)
76+
}.to raise_error(SerpApi::SerpApiError).with_message(/HTTP request failed with status: 400.* error: Missing query `q` parameter./)
7777
end
7878

7979
it 'get bad endpoint' do
@@ -90,7 +90,7 @@
9090
begin
9191
client.send(:get, '/invalid', :html, {})
9292
rescue SerpApi::SerpApiError => e
93-
expect(e.message).to include(/HTTP request failed with response status: 404 Not Found reponse/), "got #{e.message}"
93+
expect(e.message).to include("HTTP request failed with status: 404")
9494
rescue => e
9595
raise("wrong exception: #{e}")
9696
end

0 commit comments

Comments
 (0)