keener 0.1.0 → 0.1.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml ADDED
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: bda5470272ffd469565e7a0dcdc76080e14920ef
4
+ data.tar.gz: cbf263a82ae23ad8afafdde321f585e2b6cba0f5
5
+ SHA512:
6
+ metadata.gz: 79a79472075e094e68f544f65960e71982520dead251a0bd7d963f01292714d4c398a394798f88031eb665e8b86936a698fcc7094f72b88e635e38956592ef38
7
+ data.tar.gz: 2010e7654b3eda977e8d94cfa7b1110f86a34c529a0df7bc286eae89ebe5f667212c0d513fcc58351abe21653128091dcac7a8416707834b635cb49abd7bfbfc
data/.gitignore CHANGED
@@ -15,3 +15,7 @@ spec/reports
15
15
  test/tmp
16
16
  test/version_tmp
17
17
  tmp
18
+
19
+ /.DS_Store
20
+ /.ruby-gemset
21
+ /.ruby-version
data/keener.gemspec CHANGED
@@ -4,28 +4,29 @@ $LOAD_PATH.unshift(lib) unless $LOAD_PATH.include?(lib)
4
4
  require 'keener/version'
5
5
 
6
6
  Gem::Specification.new do |gem|
7
- gem.name = "keener"
7
+ gem.name = 'keener'
8
8
  gem.version = Keener::VERSION
9
- gem.authors = ["Mateo Murphy"]
10
- gem.email = ["mateo.murphy@gmail.com"]
9
+ gem.authors = ['Mateo Murphy']
10
+ gem.email = ['mateo.murphy@gmail.com']
11
11
  gem.description = %q{Unofficial gem for accessing keen.io}
12
12
  gem.summary = %q{An unofficial gem for accessing keen.io}
13
- gem.homepage = "https://github.com/mateomurphy/keener"
13
+ gem.homepage = 'https://github.com/mateomurphy/keener'
14
14
 
15
15
  gem.files = `git ls-files`.split($/)
16
16
  gem.executables = gem.files.grep(%r{^bin/}).map{ |f| File.basename(f) }
17
17
  gem.test_files = gem.files.grep(%r{^(test|spec|features)/})
18
- gem.require_paths = ["lib"]
18
+ gem.require_paths = ['lib']
19
19
 
20
- gem.add_dependency 'faraday', "~> 0.8.5"
20
+ gem.add_dependency 'faraday', '~> 0.8.5'
21
21
  gem.add_dependency 'faraday_middleware', '~> 0.9.0'
22
22
  gem.add_dependency 'hashie', '~> 1.2.0'
23
23
 
24
- gem.add_development_dependency "em-synchrony", "~> 1.0.3"
25
- gem.add_development_dependency "em-http-request", "~> 1.0.3"
26
- gem.add_development_dependency "typhoeus"
27
- gem.add_development_dependency "rspec", "~> 2.12"
28
- gem.add_development_dependency "vcr", "~> 2.4.0"
24
+ gem.add_development_dependency 'gem-release'
25
+ gem.add_development_dependency 'em-synchrony', '~> 1.0.3'
26
+ gem.add_development_dependency 'em-http-request', '~> 1.0.3'
27
+ gem.add_development_dependency 'typhoeus'
28
+ gem.add_development_dependency 'rspec', '~> 2.12'
29
+ gem.add_development_dependency 'vcr', '~> 2.4.0'
29
30
  gem.add_development_dependency 'rake'
30
31
  gem.add_development_dependency 'yard'
31
32
  gem.add_development_dependency 'redcarpet'
data/lib/keener/query.rb CHANGED
@@ -4,6 +4,7 @@ module Keener
4
4
  @project_id = project_id
5
5
  @event_collection = event_collection
6
6
  @options = options
7
+ yield self if block_given?
7
8
  end
8
9
  end
9
10
 
@@ -34,27 +35,27 @@ module Keener
34
35
  end
35
36
 
36
37
  def count
37
- Keened.count(@project_id, @event_collection, @options).get
38
+ Keener.count(@project_id, @event_collection, @options).get
38
39
  end
39
40
 
40
41
  def count_unique(target_property)
41
- Keened.count_unique(@project_id, @event_collection, target_property, @options).get
42
+ Keener.count_unique(@project_id, @event_collection, target_property, @options).get
42
43
  end
43
44
 
44
45
  def minimum(target_property)
45
- Keened.minimum(@project_id, @event_collection, target_property, @options).get
46
+ Keener.minimum(@project_id, @event_collection, target_property, @options).get
46
47
  end
47
48
 
48
49
  def maximum(target_property)
49
- Keened.maximum(@project_id, @event_collection, target_property, @options).get
50
+ Keener.maximum(@project_id, @event_collection, target_property, @options).get
50
51
  end
51
52
 
52
53
  def sum(target_property)
53
- Keened.sum(@project_id, @event_collection, target_property, @options).get
54
+ Keener.sum(@project_id, @event_collection, target_property, @options).get
54
55
  end
55
56
 
56
57
  def average(target_property)
57
- Keened.average(@project_id, @event_collection, target_property, @options).get
58
+ Keener.average(@project_id, @event_collection, target_property, @options).get
58
59
  end
59
60
  end
60
61
 
@@ -1,3 +1,3 @@
1
1
  module Keener
2
- VERSION = "0.1.0"
2
+ VERSION = "0.1.1"
3
3
  end
@@ -46,10 +46,10 @@ shared_examples 'a parallel adapter' do
46
46
  end
47
47
 
48
48
  it 'return the count' do
49
- responses.first.body.result.should eq(2757)
49
+ responses.first.body.result.should be > 2757
50
50
  end
51
51
 
52
52
  it 'returns the unique count' do
53
- responses.last.body.result.should eq(9)
53
+ responses.last.body.result.should be > 9
54
54
  end
55
55
  end
metadata CHANGED
@@ -1,20 +1,18 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: keener
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
5
- prerelease:
4
+ version: 0.1.1
6
5
  platform: ruby
7
6
  authors:
8
7
  - Mateo Murphy
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2013-02-10 00:00:00.000000000 Z
11
+ date: 2013-05-03 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: faraday
16
15
  requirement: !ruby/object:Gem::Requirement
17
- none: false
18
16
  requirements:
19
17
  - - ~>
20
18
  - !ruby/object:Gem::Version
@@ -22,7 +20,6 @@ dependencies:
22
20
  type: :runtime
23
21
  prerelease: false
24
22
  version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
23
  requirements:
27
24
  - - ~>
28
25
  - !ruby/object:Gem::Version
@@ -30,7 +27,6 @@ dependencies:
30
27
  - !ruby/object:Gem::Dependency
31
28
  name: faraday_middleware
32
29
  requirement: !ruby/object:Gem::Requirement
33
- none: false
34
30
  requirements:
35
31
  - - ~>
36
32
  - !ruby/object:Gem::Version
@@ -38,7 +34,6 @@ dependencies:
38
34
  type: :runtime
39
35
  prerelease: false
40
36
  version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
37
  requirements:
43
38
  - - ~>
44
39
  - !ruby/object:Gem::Version
@@ -46,7 +41,6 @@ dependencies:
46
41
  - !ruby/object:Gem::Dependency
47
42
  name: hashie
48
43
  requirement: !ruby/object:Gem::Requirement
49
- none: false
50
44
  requirements:
51
45
  - - ~>
52
46
  - !ruby/object:Gem::Version
@@ -54,15 +48,27 @@ dependencies:
54
48
  type: :runtime
55
49
  prerelease: false
56
50
  version_requirements: !ruby/object:Gem::Requirement
57
- none: false
58
51
  requirements:
59
52
  - - ~>
60
53
  - !ruby/object:Gem::Version
61
54
  version: 1.2.0
55
+ - !ruby/object:Gem::Dependency
56
+ name: gem-release
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - '>='
60
+ - !ruby/object:Gem::Version
61
+ version: '0'
62
+ type: :development
63
+ prerelease: false
64
+ version_requirements: !ruby/object:Gem::Requirement
65
+ requirements:
66
+ - - '>='
67
+ - !ruby/object:Gem::Version
68
+ version: '0'
62
69
  - !ruby/object:Gem::Dependency
63
70
  name: em-synchrony
64
71
  requirement: !ruby/object:Gem::Requirement
65
- none: false
66
72
  requirements:
67
73
  - - ~>
68
74
  - !ruby/object:Gem::Version
@@ -70,7 +76,6 @@ dependencies:
70
76
  type: :development
71
77
  prerelease: false
72
78
  version_requirements: !ruby/object:Gem::Requirement
73
- none: false
74
79
  requirements:
75
80
  - - ~>
76
81
  - !ruby/object:Gem::Version
@@ -78,7 +83,6 @@ dependencies:
78
83
  - !ruby/object:Gem::Dependency
79
84
  name: em-http-request
80
85
  requirement: !ruby/object:Gem::Requirement
81
- none: false
82
86
  requirements:
83
87
  - - ~>
84
88
  - !ruby/object:Gem::Version
@@ -86,7 +90,6 @@ dependencies:
86
90
  type: :development
87
91
  prerelease: false
88
92
  version_requirements: !ruby/object:Gem::Requirement
89
- none: false
90
93
  requirements:
91
94
  - - ~>
92
95
  - !ruby/object:Gem::Version
@@ -94,23 +97,20 @@ dependencies:
94
97
  - !ruby/object:Gem::Dependency
95
98
  name: typhoeus
96
99
  requirement: !ruby/object:Gem::Requirement
97
- none: false
98
100
  requirements:
99
- - - ! '>='
101
+ - - '>='
100
102
  - !ruby/object:Gem::Version
101
103
  version: '0'
102
104
  type: :development
103
105
  prerelease: false
104
106
  version_requirements: !ruby/object:Gem::Requirement
105
- none: false
106
107
  requirements:
107
- - - ! '>='
108
+ - - '>='
108
109
  - !ruby/object:Gem::Version
109
110
  version: '0'
110
111
  - !ruby/object:Gem::Dependency
111
112
  name: rspec
112
113
  requirement: !ruby/object:Gem::Requirement
113
- none: false
114
114
  requirements:
115
115
  - - ~>
116
116
  - !ruby/object:Gem::Version
@@ -118,7 +118,6 @@ dependencies:
118
118
  type: :development
119
119
  prerelease: false
120
120
  version_requirements: !ruby/object:Gem::Requirement
121
- none: false
122
121
  requirements:
123
122
  - - ~>
124
123
  - !ruby/object:Gem::Version
@@ -126,7 +125,6 @@ dependencies:
126
125
  - !ruby/object:Gem::Dependency
127
126
  name: vcr
128
127
  requirement: !ruby/object:Gem::Requirement
129
- none: false
130
128
  requirements:
131
129
  - - ~>
132
130
  - !ruby/object:Gem::Version
@@ -134,7 +132,6 @@ dependencies:
134
132
  type: :development
135
133
  prerelease: false
136
134
  version_requirements: !ruby/object:Gem::Requirement
137
- none: false
138
135
  requirements:
139
136
  - - ~>
140
137
  - !ruby/object:Gem::Version
@@ -142,49 +139,43 @@ dependencies:
142
139
  - !ruby/object:Gem::Dependency
143
140
  name: rake
144
141
  requirement: !ruby/object:Gem::Requirement
145
- none: false
146
142
  requirements:
147
- - - ! '>='
143
+ - - '>='
148
144
  - !ruby/object:Gem::Version
149
145
  version: '0'
150
146
  type: :development
151
147
  prerelease: false
152
148
  version_requirements: !ruby/object:Gem::Requirement
153
- none: false
154
149
  requirements:
155
- - - ! '>='
150
+ - - '>='
156
151
  - !ruby/object:Gem::Version
157
152
  version: '0'
158
153
  - !ruby/object:Gem::Dependency
159
154
  name: yard
160
155
  requirement: !ruby/object:Gem::Requirement
161
- none: false
162
156
  requirements:
163
- - - ! '>='
157
+ - - '>='
164
158
  - !ruby/object:Gem::Version
165
159
  version: '0'
166
160
  type: :development
167
161
  prerelease: false
168
162
  version_requirements: !ruby/object:Gem::Requirement
169
- none: false
170
163
  requirements:
171
- - - ! '>='
164
+ - - '>='
172
165
  - !ruby/object:Gem::Version
173
166
  version: '0'
174
167
  - !ruby/object:Gem::Dependency
175
168
  name: redcarpet
176
169
  requirement: !ruby/object:Gem::Requirement
177
- none: false
178
170
  requirements:
179
- - - ! '>='
171
+ - - '>='
180
172
  - !ruby/object:Gem::Version
181
173
  version: '0'
182
174
  type: :development
183
175
  prerelease: false
184
176
  version_requirements: !ruby/object:Gem::Requirement
185
- none: false
186
177
  requirements:
187
- - - ! '>='
178
+ - - '>='
188
179
  - !ruby/object:Gem::Version
189
180
  version: '0'
190
181
  description: Unofficial gem for accessing keen.io
@@ -223,33 +214,26 @@ files:
223
214
  - spec/support/shared_examples.rb
224
215
  homepage: https://github.com/mateomurphy/keener
225
216
  licenses: []
217
+ metadata: {}
226
218
  post_install_message:
227
219
  rdoc_options: []
228
220
  require_paths:
229
221
  - lib
230
222
  required_ruby_version: !ruby/object:Gem::Requirement
231
- none: false
232
223
  requirements:
233
- - - ! '>='
224
+ - - '>='
234
225
  - !ruby/object:Gem::Version
235
226
  version: '0'
236
- segments:
237
- - 0
238
- hash: 134372974807999632
239
227
  required_rubygems_version: !ruby/object:Gem::Requirement
240
- none: false
241
228
  requirements:
242
- - - ! '>='
229
+ - - '>='
243
230
  - !ruby/object:Gem::Version
244
231
  version: '0'
245
- segments:
246
- - 0
247
- hash: 134372974807999632
248
232
  requirements: []
249
233
  rubyforge_project:
250
- rubygems_version: 1.8.24
234
+ rubygems_version: 2.0.0
251
235
  signing_key:
252
- specification_version: 3
236
+ specification_version: 4
253
237
  summary: An unofficial gem for accessing keen.io
254
238
  test_files:
255
239
  - spec/adapters_spec.rb