soapy_cake 1.7.2 → 1.8.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: f734b8e9381f7bbca9559e4d57f507136973c0eb
4
- data.tar.gz: a6e5eea51cf350523cb33f49214f6f73efbff7cf
3
+ metadata.gz: 90201356e6d2385c37b53e49e865c434402896b7
4
+ data.tar.gz: 28dcc83c8a090dc0fb98840456d826a43dd7811c
5
5
  SHA512:
6
- metadata.gz: bb60c6a3a8a3be6f42e1b573820d47557402cf476354914e26bb54869cbe59146233e8c77b6f4bf98f5330280d8a962cdad2270501c655d0138f40de0ad04911
7
- data.tar.gz: 82712fbdadbfec95211fe6d2632fe559f5d9419ea8924ba76e80c8cb7e665d416f5d925f4477350d18ff898bd41ddee551f11a7467b4ba4a765fb785fe9eb439
6
+ metadata.gz: 43dafa8fb75b0df882c4d8fdf76536c86b5de504dee9a32b44d8023339b325a6b66873a8ecbeaf46d592eacf11b74f29f40e9de88152a718bf411a97817386fe
7
+ data.tar.gz: 611d5795f76310439df20c03d9bb0f3d8159f0f0a13ec8fa19fb3b249c8f6fa7d0fb75e06f6a8c076d87ce155310d4e85d73304a7b04522f5e4d8426d93a3bee
@@ -132,7 +132,6 @@ module SoapyCake
132
132
  require_params(opts, %i(cap_type_id cap_interval_id cap_amount send_alert_only))
133
133
 
134
134
  translate_values!(opts, %i(cap_type_id cap_interval_id))
135
- opts[:cap_amount] = -1 if opts[:cap_interval_id] == const_lookup(:cap_interval_id, :disabled)
136
135
 
137
136
  run Request.new(:admin, :addedit, :caps, opts)
138
137
  end
@@ -50,7 +50,7 @@ module SoapyCake
50
50
  conversion: 2
51
51
  },
52
52
  cap_interval_id: {
53
- disabled: 0,
53
+ indefinite: 0,
54
54
  daily: 1,
55
55
  weekly: 2,
56
56
  monthly: 3
@@ -1,3 +1,3 @@
1
1
  module SoapyCake
2
- VERSION = '1.7.2'
2
+ VERSION = '1.8.0'
3
3
  end
@@ -217,18 +217,6 @@ RSpec.describe SoapyCake::AdminAddedit do
217
217
 
218
218
  expect(result[:message]).to eq('Cap Updated')
219
219
  end
220
-
221
- it 'removes a cap for an offer contract', :vcr do
222
- result = subject.update_caps(
223
- offer_contract_id: offer_contract_id,
224
- cap_type_id: :conversion,
225
- cap_interval_id: :disabled,
226
- cap_amount: 42,
227
- send_alert_only: false
228
- )
229
-
230
- expect(result[:message]).to eq('Cap Updated')
231
- end
232
220
  end
233
221
 
234
222
  describe 'offer tiers' do
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: soapy_cake
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.7.2
4
+ version: 1.8.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - ad2games GmbH
@@ -201,7 +201,6 @@ files:
201
201
  - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/affiliates/edits_affiliates.yml
202
202
  - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/contacts/edits_a_contact.yml
203
203
  - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/geo_targeting/creates_geo_targetings.yml
204
- - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/offer_/_offer_contract_caps/removes_a_cap_for_an_offer_contract.yml
205
204
  - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/offer_/_offer_contract_caps/updates_a_cap_for_an_offer_contract.yml
206
205
  - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/offer_contracts/creates_an_offer_contract.yml
207
206
  - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/offer_contracts/updates_an_offer_contract.yml
@@ -251,7 +250,6 @@ test_files:
251
250
  - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/affiliates/edits_affiliates.yml
252
251
  - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/contacts/edits_a_contact.yml
253
252
  - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/geo_targeting/creates_geo_targetings.yml
254
- - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/offer_/_offer_contract_caps/removes_a_cap_for_an_offer_contract.yml
255
253
  - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/offer_/_offer_contract_caps/updates_a_cap_for_an_offer_contract.yml
256
254
  - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/offer_contracts/creates_an_offer_contract.yml
257
255
  - spec/fixtures/vcr_cassettes/SoapyCake_AdminAddedit/offer_contracts/updates_an_offer_contract.yml
@@ -1,53 +0,0 @@
1
- ---
2
- http_interactions:
3
- - request:
4
- method: post
5
- uri: https://cake-partner-domain.com/api/1/addedit.asmx
6
- body:
7
- encoding: UTF-8
8
- string: |
9
- <?xml version="1.0"?>
10
- <env:Envelope xmlns:env="http://www.w3.org/2003/05/soap-envelope" xmlns:cake="http://cakemarketing.com/api/1/">
11
- <env:Header/>
12
- <env:Body>
13
- <cake:Caps>
14
- <cake:api_key>cake-api-key</cake:api_key>
15
- <cake:offer_contract_id>1456</cake:offer_contract_id>
16
- <cake:cap_type_id>2</cake:cap_type_id>
17
- <cake:cap_interval_id>0</cake:cap_interval_id>
18
- <cake:cap_amount>-1</cake:cap_amount>
19
- <cake:send_alert_only>false</cake:send_alert_only>
20
- </cake:Caps>
21
- </env:Body>
22
- </env:Envelope>
23
- headers:
24
- Content-Type:
25
- - application/soap+xml;charset=UTF-8
26
- response:
27
- status:
28
- code: 200
29
- message: OK
30
- headers:
31
- Cache-Control:
32
- - private, max-age=0
33
- Content-Type:
34
- - application/soap+xml; charset=utf-8
35
- Server:
36
- - Microsoft-IIS/8.0
37
- X-Aspnet-Version:
38
- - 4.0.30319
39
- X-Powered-By:
40
- - ASP.NET
41
- Date:
42
- - Tue, 17 Feb 2015 14:00:08 GMT
43
- Content-Length:
44
- - '391'
45
- body:
46
- encoding: UTF-8
47
- string: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://www.w3.org/2003/05/soap-envelope"
48
- xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><CapsResponse
49
- xmlns="http://cakemarketing.com/api/1/"><CapsResult><success>true</success><message>Cap
50
- Updated</message></CapsResult></CapsResponse></soap:Body></soap:Envelope>
51
- http_version:
52
- recorded_at: Tue, 17 Feb 2015 14:00:11 GMT
53
- recorded_with: VCR 2.9.3