gyftwrapper 0.1.2 → 0.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -58,6 +58,12 @@ describe Gyftwrapper::API do
58
58
  end
59
59
  end
60
60
  end
61
+
62
+ describe '.get_merchants', :vcr do
63
+ it 'returns list of merchants' do
64
+ expect(subject.get_merchants.first.name).to eq('1-800-Baskets.com')
65
+ end
66
+ end
61
67
  end
62
68
 
63
69
  context 'without configs' do
@@ -8,6 +8,13 @@ describe Gyftwrapper do
8
8
  end
9
9
  end
10
10
 
11
+ describe '.get_merchants' do
12
+ it 'calls send request method with appropriate call type' do
13
+ expect(Gyftwrapper).to receive(:send_request).with(:get_merchants)
14
+ Gyftwrapper.get_merchants
15
+ end
16
+ end
17
+
11
18
  describe '.send_request' do
12
19
  let(:api) { double('api', purchase: true) }
13
20
 
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gyftwrapper
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.2
4
+ version: 0.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Ruslan Milevskiy
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-06-17 00:00:00.000000000 Z
11
+ date: 2015-08-19 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rest-client
@@ -138,6 +138,7 @@ files:
138
138
  - lib/gyftwrapper.rb
139
139
  - lib/gyftwrapper/api.rb
140
140
  - lib/gyftwrapper/version.rb
141
+ - spec/cassettes/Gyftwrapper_API/with_configs/_get_merchants/returns_list_of_merchants.yml
141
142
  - spec/cassettes/Gyftwrapper_API/with_configs/_purchase_card/for_invalid_params/shop_card_id/returns_error.yml
142
143
  - spec/cassettes/Gyftwrapper_API/with_configs/_purchase_card/for_invalid_params/shop_card_id/returns_unsuccessful_result.yml
143
144
  - spec/cassettes/Gyftwrapper_API/with_configs/_purchase_card/for_invalid_params/to_email/returns_error.yml
@@ -174,6 +175,7 @@ signing_key:
174
175
  specification_version: 4
175
176
  summary: Ruby gem for Gyft API
176
177
  test_files:
178
+ - spec/cassettes/Gyftwrapper_API/with_configs/_get_merchants/returns_list_of_merchants.yml
177
179
  - spec/cassettes/Gyftwrapper_API/with_configs/_purchase_card/for_invalid_params/shop_card_id/returns_error.yml
178
180
  - spec/cassettes/Gyftwrapper_API/with_configs/_purchase_card/for_invalid_params/shop_card_id/returns_unsuccessful_result.yml
179
181
  - spec/cassettes/Gyftwrapper_API/with_configs/_purchase_card/for_invalid_params/to_email/returns_error.yml