eucalyptus 0.2.2 → 0.2.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/VERSION +1 -1
- data/eucalyptus.gemspec +2 -2
- data/lib/eucalyptus/account.rb +0 -6
- data/lib/eucalyptus/ad.rb +0 -1
- data/lib/eucalyptus/ad_set.rb +0 -2
- data/lib/eucalyptus/campaign.rb +0 -4
- data/lib/eucalyptus/resource.rb +16 -0
- data/spec/eucalyptus/account_spec.rb +2 -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: 21c83f716d9b6569822426c81c7ba15cea39f4e6
|
4
|
+
data.tar.gz: f8e8f7d74ed99cf702c62bb84e83979faf18b8a0
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f3e0ffc746395b8d255072e087a4b11e514406d1453b5edc0c92dc62f4e337d2e0c9f9bb02c4cb9808854f319bdf3fe59d338314b97dcb931becc547e06c886d
|
7
|
+
data.tar.gz: b66cbc6c47a1974f805ff3d0df784808969dade1a18ca56b62e61aa5f9b68a73bcbfc8c66b0b19ad33cb4c83a674f72e9cd8e2c3d38b1c2f5e7d3d9c2820e0bc
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.3
|
data/eucalyptus.gemspec
CHANGED
@@ -2,11 +2,11 @@
|
|
2
2
|
# DO NOT EDIT THIS FILE DIRECTLY
|
3
3
|
# Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
|
4
4
|
# -*- encoding: utf-8 -*-
|
5
|
-
# stub: eucalyptus 0.2.
|
5
|
+
# stub: eucalyptus 0.2.3 ruby lib
|
6
6
|
|
7
7
|
Gem::Specification.new do |s|
|
8
8
|
s.name = "eucalyptus"
|
9
|
-
s.version = "0.2.
|
9
|
+
s.version = "0.2.3"
|
10
10
|
|
11
11
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
12
12
|
s.require_paths = ["lib"]
|
data/lib/eucalyptus/account.rb
CHANGED
@@ -51,11 +51,5 @@ module Eucalyptus
|
|
51
51
|
def self.parent
|
52
52
|
OpenStruct.new(id: "me")
|
53
53
|
end
|
54
|
-
|
55
|
-
# ASSOCIATOINS
|
56
|
-
def ads; Ad.all(parent: self); end
|
57
|
-
def ad_sets; AdSet.all(parent: self); end
|
58
|
-
def campaigns; Campaign.all(parent: self); end
|
59
|
-
def insights; Insight.all(parent: self); end
|
60
54
|
end
|
61
55
|
end
|
data/lib/eucalyptus/ad.rb
CHANGED
data/lib/eucalyptus/ad_set.rb
CHANGED
data/lib/eucalyptus/campaign.rb
CHANGED
data/lib/eucalyptus/resource.rb
CHANGED
@@ -41,5 +41,21 @@ module Eucalyptus
|
|
41
41
|
def respond_to?(method_sym, include_private = false)
|
42
42
|
@response.respond_to?(method_sym)
|
43
43
|
end
|
44
|
+
|
45
|
+
def ads(options={})
|
46
|
+
Ad.all(parent: self, options: options)
|
47
|
+
end
|
48
|
+
|
49
|
+
def campaigns(options={})
|
50
|
+
Campaign.all(parent: self, options: options)
|
51
|
+
end
|
52
|
+
|
53
|
+
def ad_sets(options={})
|
54
|
+
AdSet.all(parent: self, options: options)
|
55
|
+
end
|
56
|
+
|
57
|
+
def insights(options={})
|
58
|
+
Insight.all(parent: self, options: options)
|
59
|
+
end
|
44
60
|
end
|
45
61
|
end
|
@@ -11,7 +11,7 @@ describe Eucalyptus::Account do
|
|
11
11
|
|
12
12
|
describe '#insights' do
|
13
13
|
it 'returns an array of insights for the account' do
|
14
|
-
VCR.use_cassette("
|
14
|
+
VCR.use_cassette("account_insights") do
|
15
15
|
expect(account.insights).to be_a Array
|
16
16
|
expect(account.insights.first).to be_a Eucalyptus::Insight
|
17
17
|
end
|
@@ -37,7 +37,7 @@ describe Eucalyptus::Account do
|
|
37
37
|
end
|
38
38
|
|
39
39
|
describe '#campaigns' do
|
40
|
-
it 'returns a collection of
|
40
|
+
it 'returns a collection of Campaign objects which belong to the account' do
|
41
41
|
VCR.use_cassette("account_campaigns") do
|
42
42
|
expect(account.campaigns).to be_a Array
|
43
43
|
expect(account.campaigns.first).to be_a Eucalyptus::Campaign
|