Skip to content

Commit 6b254ba

Browse files
authored
Use correct field name in mocked response body (#454)
1 parent 1a9da1e commit 6b254ba

1 file changed

Lines changed: 4 additions & 4 deletions

File tree

spec/line/bot/v2/misc_spec.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -251,7 +251,7 @@
251251
let(:response_code) { 200 }
252252

253253
it 'returns a list of followers successfully without optional parameters' do
254-
response_body = { "user_ids" => ["U1234567890", "U0987654321"] }.to_json
254+
response_body = { "userIds" => ["U1234567890", "U0987654321"] }.to_json
255255
stub_request(:get, "https://api.line.me/v2/bot/followers/ids")
256256
.with(
257257
headers: {
@@ -267,7 +267,7 @@
267267
end
268268

269269
it 'query with only start' do
270-
response_body = { "user_ids" => ["U1234567890", "U0987654321"], "next" => "nExT Token" }.to_json
270+
response_body = { "userIds" => ["U1234567890", "U0987654321"], "next" => "nExT Token" }.to_json
271271
stub_request(:get, "https://api.line.me/v2/bot/followers/ids?start=from%20previous%20NEXT")
272272
.with(
273273
headers: {
@@ -284,7 +284,7 @@
284284
end
285285

286286
it 'query with limit and start' do
287-
response_body = { "user_ids" => ["U1234567890", "U0987654321"], "next" => "nExT Token" }.to_json
287+
response_body = { "userIds" => ["U1234567890", "U0987654321"], "next" => "nExT Token" }.to_json
288288
stub_request(:get, "https://api.line.me/v2/bot/followers/ids?limit=10&start=from%20previous%20NEXT")
289289
.with(
290290
headers: {
@@ -519,7 +519,7 @@
519519

520520
describe 'GET /v2/bot/message/aggregation/list' do
521521
let(:client) { Line::Bot::V2::MessagingApi::ApiClient.new(channel_access_token: 'test-channel-access-token') }
522-
let(:response_body) { { "custom_aggregation_units" => ["unit1", "unit2"], "next" => "token" }.to_json }
522+
let(:response_body) { { "customAggregationUnits" => ["unit1", "unit2"], "next" => "token" }.to_json }
523523
let(:response_code) { 200 }
524524

525525
it 'returns a list of aggregation units successfully without optional parameters' do

0 commit comments

Comments
 (0)