rakuten_web_service 1.1.0 → 1.1.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +6 -0
- data/examples/books_item_search.rb +1 -3
- data/examples/gora_search.rb +1 -3
- data/lib/rakuten_web_service/gora/course_detail.rb +2 -2
- data/lib/rakuten_web_service/gora/plan.rb +2 -2
- data/lib/rakuten_web_service/ichiba/genre.rb +2 -1
- data/lib/rakuten_web_service/kobo/ebook.rb +0 -2
- data/lib/rakuten_web_service/version.rb +1 -1
- data/spec/rakuten_web_service/gora/course_detail_spec.rb +0 -2
- data/spec/rakuten_web_service/gora/course_spec.rb +0 -2
- data/spec/rakuten_web_service/gora/plan_spec.rb +0 -2
- data/spec/rakuten_web_service/ichiba/genre_spec.rb +4 -2
- data/spec/rakuten_web_service/ichiba/item_spec.rb +1 -1
- data/spec/rakuten_web_service/ichiba/product_search_spec.rb +0 -1
- data/spec/rakuten_web_service/kobo/ebook_spec.rb +0 -2
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 7e2855adb7ca963009ff82d05b90aeddd2935155
|
4
|
+
data.tar.gz: e21538cc0291246f23e5c034becaae09ed77d843
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: d7d85a610f4cbfc9dcb823912b3c99fccd2cb0495d665d0ea504a658b27b91018dd0de9768c0d21e2ca88367d8e1cd956f92c4f484916abff365c0f6ef606bac
|
7
|
+
data.tar.gz: 15d281c03306b0dd15a85627870c727505b34547197fc19648032bfda68af3229fded98b5dc43bb97a3f20f82efecebb271589b2d4d3456d21b8222620c41e64
|
data/CHANGELOG.md
CHANGED
@@ -1,6 +1,4 @@
|
|
1
|
-
#
|
2
|
-
#
|
3
|
-
# This is a sample script f Rakuten Books APIs.
|
1
|
+
# This is a sample script of Rakuten Books APIs.
|
4
2
|
# RWS Ruby SDK supports Books API. The inteface is similar to ones Ichiba API.
|
5
3
|
# If you want to search CDs dealt in Rakuten Books, you can do it with `RakutenWebService::Books::CD`.
|
6
4
|
# As for other resources, there are `RakutenWebService::Books::Book`, `RakutenWebService::Books::DVD` and so on.
|
data/examples/gora_search.rb
CHANGED
@@ -1,6 +1,4 @@
|
|
1
|
-
#
|
2
|
-
#
|
3
|
-
# This is a sample script f Rakuten Gora APIs.
|
1
|
+
# This is a sample script of Rakuten Gora APIs.
|
4
2
|
# RWS Ruby SDK supports Gora API. The inteface is similar to ones Ichiba API.
|
5
3
|
# If you want to search courses dealt in Rakuten Gora, you can do it with `RakutenWebService::Gora::Course`.
|
6
4
|
# As for other resources, there are `RakutenWebService::Gora::CourseDetail`, `RakutenWebService::Gora::Plan` and so on.
|
@@ -34,7 +34,7 @@ module RakutenWebService
|
|
34
34
|
|
35
35
|
class Rating < Resource
|
36
36
|
class << self
|
37
|
-
def search(
|
37
|
+
def search(_options)
|
38
38
|
raise 'There is no API endpoint for this resource.'
|
39
39
|
end
|
40
40
|
end
|
@@ -44,7 +44,7 @@ module RakutenWebService
|
|
44
44
|
|
45
45
|
class Plan < Resource
|
46
46
|
class << self
|
47
|
-
def search(
|
47
|
+
def search(_options)
|
48
48
|
raise 'There is no API endpoint for this resource.'
|
49
49
|
end
|
50
50
|
end
|
@@ -19,7 +19,7 @@ module RakutenWebService
|
|
19
19
|
|
20
20
|
class PlanInfo < Resource
|
21
21
|
class << self
|
22
|
-
def search(
|
22
|
+
def search(_options)
|
23
23
|
raise 'There is no API endpoint for this resource.'
|
24
24
|
end
|
25
25
|
end
|
@@ -35,7 +35,7 @@ module RakutenWebService
|
|
35
35
|
|
36
36
|
class CallInfo < Resource
|
37
37
|
class << self
|
38
|
-
def search(
|
38
|
+
def search(_options)
|
39
39
|
raise 'There is no API endpoint for this resource.'
|
40
40
|
end
|
41
41
|
end
|
@@ -12,7 +12,8 @@ module RakutenWebService
|
|
12
12
|
root_id 0
|
13
13
|
|
14
14
|
def ranking(options={})
|
15
|
-
|
15
|
+
options = options.merge(genre_id: self.id)
|
16
|
+
RakutenWebService::Ichiba::RankingItem.search(options)
|
16
17
|
end
|
17
18
|
|
18
19
|
def products(options={})
|
@@ -1,5 +1,3 @@
|
|
1
|
-
# encoding: utf-8
|
2
|
-
|
3
1
|
require 'spec_helper'
|
4
2
|
|
5
3
|
describe RakutenWebService::Ichiba::Genre do
|
@@ -155,6 +153,10 @@ describe RakutenWebService::Ichiba::Genre do
|
|
155
153
|
expect(RakutenWebService::Ichiba::RankingItem).to receive(:search).with(:genre_id => genre_id)
|
156
154
|
expect { genre.ranking }.to_not raise_error
|
157
155
|
end
|
156
|
+
specify "should call RankingItem's search with genre_id and given options" do
|
157
|
+
expect(RakutenWebService::Ichiba::RankingItem).to receive(:search).with(genre_id: genre_id, age: 10)
|
158
|
+
expect { genre.ranking(age: 10) }.to_not raise_error
|
159
|
+
end
|
158
160
|
end
|
159
161
|
|
160
162
|
describe '#products' do
|