hasoffersv3 0.2.4 → 0.2.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/CHANGELOG.md +3 -0
- data/lib/hasoffersv3/application.rb +9 -0
- data/lib/hasoffersv3/configuration.rb +1 -1
- data/lib/hasoffersv3/version.rb +1 -1
- data/lib/hasoffersv3.rb +3 -2
- data/spec/lib/affiliate_offer_spec.rb +1 -1
- data/spec/lib/application_spec.rb +15 -0
- data/spec/lib/client_spec.rb +2 -2
- metadata +5 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 14bbd72a409f04c3d63cf07b9417afdde9c296a7
|
4
|
+
data.tar.gz: 94b5449a542c94b181efa8f3b83fe34b45304f18
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: aa0db833b68b053dd514b5a0f6fde0ed8a8152f7f5c9f7b4256133afca5d83275313e0cd5d95d2d848b9b973f440eb5750ff4b435cfb1749aba0a674da7555c3
|
7
|
+
data.tar.gz: be9248e2502ead5ab04769039b52017f1cca049de8b9a8801ae29e8d03166b4bfcbd9593f74ae9b994f7b5e7dead15b76d80f31e12e73014b54ad9f41c86161c
|
data/CHANGELOG.md
CHANGED
data/lib/hasoffersv3/version.rb
CHANGED
data/lib/hasoffersv3.rb
CHANGED
@@ -3,7 +3,7 @@ require 'json'
|
|
3
3
|
|
4
4
|
require 'hasoffersv3/client'
|
5
5
|
|
6
|
-
%w!base affiliate response conversion raw_log report configuration advertiser advertiser_user offer!.each do |file|
|
6
|
+
%w!base affiliate response conversion raw_log report configuration advertiser advertiser_user offer application!.each do |file|
|
7
7
|
require "hasoffersv3/#{file}"
|
8
8
|
end
|
9
9
|
|
@@ -24,7 +24,8 @@ class HasOffersV3
|
|
24
24
|
conversions: HasOffersV3::Conversion,
|
25
25
|
offers: HasOffersV3::Offer,
|
26
26
|
raw_logs: HasOffersV3::RawLog,
|
27
|
-
reports: HasOffersV3::Report
|
27
|
+
reports: HasOffersV3::Report,
|
28
|
+
application: HasOffersV3::Application
|
28
29
|
}
|
29
30
|
|
30
31
|
class << self
|
@@ -10,7 +10,7 @@ describe HasOffersV3::AffiliateOffer do
|
|
10
10
|
end
|
11
11
|
|
12
12
|
context 'urls' do
|
13
|
-
specify { expect(url).to eq('
|
13
|
+
specify { expect(url).to eq('https://api.hasoffers.com/v3/Affiliate_Offer.json') }
|
14
14
|
end
|
15
15
|
|
16
16
|
describe '.find_all' do
|
@@ -0,0 +1,15 @@
|
|
1
|
+
require 'spec_helper'
|
2
|
+
|
3
|
+
describe HasOffersV3::Application do
|
4
|
+
let(:url) { Regexp.new api_url('Application') }
|
5
|
+
|
6
|
+
describe '.get_payout_tiers' do
|
7
|
+
subject { HasOffersV3::Application }
|
8
|
+
it 'should make a proper request call' do
|
9
|
+
stub_call :get
|
10
|
+
response = subject.get_payout_tiers
|
11
|
+
expect(a_request(:get, url).with(query: hash_including({'Method' => 'findAllAffiliateTiers'}))).to have_been_made
|
12
|
+
validate_call response
|
13
|
+
end
|
14
|
+
end
|
15
|
+
end
|
data/spec/lib/client_spec.rb
CHANGED
@@ -13,10 +13,10 @@ describe HasOffersV3::Client do
|
|
13
13
|
|
14
14
|
it 'should be different configs' do
|
15
15
|
default_connection = HasOffersV3::Client.new(configuration_to_default_host)
|
16
|
-
expect(default_connection.base_uri).to eq('
|
16
|
+
expect(default_connection.base_uri).to eq('https://api.hasoffers.com/v3')
|
17
17
|
|
18
18
|
proxy_connection = HasOffersV3::Client.new(config_for_proxy)
|
19
|
-
expect(proxy_connection.base_uri).to eq('
|
19
|
+
expect(proxy_connection.base_uri).to eq('https://api.applift.com/v3')
|
20
20
|
end
|
21
21
|
|
22
22
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: hasoffersv3
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Maximilian Seifert
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2015-
|
12
|
+
date: 2015-07-31 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: activesupport
|
@@ -108,6 +108,7 @@ files:
|
|
108
108
|
- lib/hasoffersv3/affiliate.rb
|
109
109
|
- lib/hasoffersv3/affiliate_billing.rb
|
110
110
|
- lib/hasoffersv3/affiliate_offer.rb
|
111
|
+
- lib/hasoffersv3/application.rb
|
111
112
|
- lib/hasoffersv3/base.rb
|
112
113
|
- lib/hasoffersv3/client.rb
|
113
114
|
- lib/hasoffersv3/configuration.rb
|
@@ -125,6 +126,7 @@ files:
|
|
125
126
|
- spec/lib/affiliate_billing_spec.rb
|
126
127
|
- spec/lib/affiliate_offer_spec.rb
|
127
128
|
- spec/lib/affiliate_spec.rb
|
129
|
+
- spec/lib/application_spec.rb
|
128
130
|
- spec/lib/base_spec.rb
|
129
131
|
- spec/lib/client_spec.rb
|
130
132
|
- spec/lib/conversion_spec.rb
|
@@ -165,6 +167,7 @@ test_files:
|
|
165
167
|
- spec/lib/affiliate_billing_spec.rb
|
166
168
|
- spec/lib/affiliate_offer_spec.rb
|
167
169
|
- spec/lib/affiliate_spec.rb
|
170
|
+
- spec/lib/application_spec.rb
|
168
171
|
- spec/lib/base_spec.rb
|
169
172
|
- spec/lib/client_spec.rb
|
170
173
|
- spec/lib/conversion_spec.rb
|