amee 4.3.2 → 4.4.0
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG.txt +6 -0
- data/Gemfile +7 -1
- data/Rakefile +2 -0
- data/VERSION +1 -1
- data/amee.gemspec +57 -6
- data/amee_test_credentials.example.yml +11 -0
- data/cassettes/AMEE_Connection/v2/raising_unhandled_errors.yml +36 -0
- data/cassettes/AMEE_Connection/v3/retries/502.yml +36 -0
- data/cassettes/AMEE_Connection/v3/retries/503.yml +36 -0
- data/cassettes/AMEE_Connection/v3/retries/504.yml +36 -0
- data/cassettes/AMEE_Connection/v3/retries/AMEE_TimeOut.yml +36 -0
- data/cassettes/AMEE_Connection/v3/should_be_able_to_get_from_meta_server.yml +30 -0
- data/cassettes/AMEE_Connection/v3/should_be_able_to_handle_failed_gets_from_meta_server.yml +30 -0
- data/cassettes/AMEE_Connection/v3/should_be_able_to_post_to_meta_server.yml +59 -0
- data/cassettes/AMEE_Connection/v3/should_have_a_connection_to_meta_server.yml +36 -0
- data/cassettes/AMEE_Connection/v3/should_login_and_know_the_path_to_the_server.yml +36 -0
- data/cassettes/AMEE_Connection_Caching_Off/authenticating.yml +36 -0
- data/cassettes/AMEE_Connection_Caching_Off/first_request.yml +40 -0
- data/cassettes/AMEE_Connection_Caching_Off/second_request.yml +40 -0
- data/cassettes/AMEE_Connection_Caching_On/authenticating.yml +36 -0
- data/cassettes/AMEE_Connection_Caching_On/first_request.yml +40 -0
- data/cassettes/AMEE_Connection_Caching_clear_all/second_request.yml +40 -0
- data/cassettes/AMEE_Connection_Caching_clear_manually/second_request.yml +40 -0
- data/cassettes/AMEE_Connection_Caching_further_down_tree/second_request.yml +79 -0
- data/cassettes/AMEE_Connection_with_authentication/handling_404s.yml +69 -0
- data/cassettes/AMEE_Connection_with_authentication/hitting_private_urls.yml +75 -0
- data/cassettes/AMEE_Connection_with_authentication/raising_errors_if_permission_denied.yml +69 -0
- data/cassettes/AMEE_Connection_with_authentication/should_re-authenticate_and_refresh_authtoken_when_authtoken_expires.yml +104 -0
- data/cassettes/AMEE_Connection_with_authentication/should_refresh_authtoken_when_authtoken_is_changed.yml +114 -0
- data/cassettes/AMEE_Connection_with_authentication/using_a_v1_key.yml +71 -0
- data/cassettes/AMEE_Connection_with_authentication/using_a_v2_key/detects_the_API_version_for_JSON.yml +36 -0
- data/cassettes/AMEE_Connection_with_authentication/using_a_v2_key/detects_the_API_version_for_XML.yml +36 -0
- data/cassettes/AMEE_Connection_with_authentication_doing_write-requests.yml +75 -0
- data/cassettes/AMEE_Connection_with_authentication_doing_write-requests/working_with_an_existing_profile/deleting_existing_items.yml +108 -0
- data/cassettes/AMEE_Connection_with_authentication_doing_write-requests/working_with_an_existing_profile/sending_updates_to_existing_items.yml +108 -0
- data/cassettes/AMEE_Connection_with_bad_authentication_information/hitting_a_private_url.yml +29 -0
- data/cassettes/AMEE_Connection_with_bad_authentication_information/hitting_a_public_url.yml +32 -0
- data/cassettes/AMEE_Connection_with_incorrect_server_name.yml +16 -0
- data/cassettes/AMEE_Connection_with_retry_enabled.yml +36 -0
- data/lib/amee/connection.rb +234 -110
- data/lib/amee/data_category.rb +2 -2
- data/lib/amee/data_item.rb +45 -2
- data/lib/amee/data_item_value.rb +1 -1
- data/lib/amee/exceptions.rb +5 -2
- data/lib/amee/parse_helper.rb +2 -0
- data/lib/amee/profile_item.rb +6 -2
- data/lib/amee/v3/connection.rb +77 -70
- data/lib/amee/v3/item_value_definition.rb +1 -1
- data/lib/amee/v3/return_value_definition.rb +1 -1
- data/spec/cache_spec.rb +107 -48
- data/spec/connection_spec.rb +224 -183
- data/spec/data_item_spec.rb +12 -0
- data/spec/data_item_value_history_spec.rb +4 -4
- data/spec/data_item_value_spec.rb +2 -2
- data/spec/fixtures/AD63A83B4D41.json +1 -1
- data/spec/fixtures/AD63A83B4D41.xml +1 -1
- data/spec/profile_item_spec.rb +14 -10
- data/spec/spec_helper.rb +29 -0
- data/spec/v3/connection_spec.rb +77 -65
- data/spec/v3/item_value_definition_spec.rb +1 -0
- data/spec/v3/return_value_definition_spec.rb +1 -1
- metadata +140 -24
- data/Gemfile.lock +0 -63
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: amee
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 47
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 4
|
8
|
-
-
|
9
|
-
-
|
10
|
-
version: 4.
|
8
|
+
- 4
|
9
|
+
- 0
|
10
|
+
version: 4.4.0
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- James Smith
|
@@ -18,7 +18,7 @@ autorequire:
|
|
18
18
|
bindir: bin
|
19
19
|
cert_chain: []
|
20
20
|
|
21
|
-
date: 2012-01-
|
21
|
+
date: 2012-01-26 00:00:00 Z
|
22
22
|
dependencies:
|
23
23
|
- !ruby/object:Gem::Dependency
|
24
24
|
requirement: &id001 !ruby/object:Gem::Requirement
|
@@ -84,18 +84,45 @@ dependencies:
|
|
84
84
|
requirements:
|
85
85
|
- - ~>
|
86
86
|
- !ruby/object:Gem::Version
|
87
|
-
hash:
|
87
|
+
hash: 7
|
88
88
|
segments:
|
89
89
|
- 1
|
90
90
|
- 4
|
91
|
-
|
92
|
-
version: 1.4.4
|
91
|
+
version: "1.4"
|
93
92
|
version_requirements: *id005
|
94
93
|
name: nokogiri
|
95
94
|
prerelease: false
|
96
95
|
type: :runtime
|
97
96
|
- !ruby/object:Gem::Dependency
|
98
97
|
requirement: &id006 !ruby/object:Gem::Requirement
|
98
|
+
none: false
|
99
|
+
requirements:
|
100
|
+
- - ">="
|
101
|
+
- !ruby/object:Gem::Version
|
102
|
+
hash: 3
|
103
|
+
segments:
|
104
|
+
- 0
|
105
|
+
version: "0"
|
106
|
+
version_requirements: *id006
|
107
|
+
name: typhoeus
|
108
|
+
prerelease: false
|
109
|
+
type: :runtime
|
110
|
+
- !ruby/object:Gem::Dependency
|
111
|
+
requirement: &id007 !ruby/object:Gem::Requirement
|
112
|
+
none: false
|
113
|
+
requirements:
|
114
|
+
- - ">="
|
115
|
+
- !ruby/object:Gem::Version
|
116
|
+
hash: 3
|
117
|
+
segments:
|
118
|
+
- 0
|
119
|
+
version: "0"
|
120
|
+
version_requirements: *id007
|
121
|
+
name: log_buddy
|
122
|
+
prerelease: false
|
123
|
+
type: :runtime
|
124
|
+
- !ruby/object:Gem::Dependency
|
125
|
+
requirement: &id008 !ruby/object:Gem::Requirement
|
99
126
|
none: false
|
100
127
|
requirements:
|
101
128
|
- - ~>
|
@@ -106,12 +133,12 @@ dependencies:
|
|
106
133
|
- 0
|
107
134
|
- 0
|
108
135
|
version: 1.0.0
|
109
|
-
version_requirements: *
|
136
|
+
version_requirements: *id008
|
110
137
|
name: bundler
|
111
138
|
prerelease: false
|
112
139
|
type: :development
|
113
140
|
- !ruby/object:Gem::Dependency
|
114
|
-
requirement: &
|
141
|
+
requirement: &id009 !ruby/object:Gem::Requirement
|
115
142
|
none: false
|
116
143
|
requirements:
|
117
144
|
- - ~>
|
@@ -122,12 +149,12 @@ dependencies:
|
|
122
149
|
- 6
|
123
150
|
- 4
|
124
151
|
version: 1.6.4
|
125
|
-
version_requirements: *
|
152
|
+
version_requirements: *id009
|
126
153
|
name: jeweler
|
127
154
|
prerelease: false
|
128
155
|
type: :development
|
129
156
|
- !ruby/object:Gem::Dependency
|
130
|
-
requirement: &
|
157
|
+
requirement: &id010 !ruby/object:Gem::Requirement
|
131
158
|
none: false
|
132
159
|
requirements:
|
133
160
|
- - "="
|
@@ -138,12 +165,12 @@ dependencies:
|
|
138
165
|
- 6
|
139
166
|
- 0
|
140
167
|
version: 2.6.0
|
141
|
-
version_requirements: *
|
168
|
+
version_requirements: *id010
|
142
169
|
name: rspec
|
143
170
|
prerelease: false
|
144
171
|
type: :development
|
145
172
|
- !ruby/object:Gem::Dependency
|
146
|
-
requirement: &
|
173
|
+
requirement: &id011 !ruby/object:Gem::Requirement
|
147
174
|
none: false
|
148
175
|
requirements:
|
149
176
|
- - ">"
|
@@ -154,12 +181,12 @@ dependencies:
|
|
154
181
|
- 8
|
155
182
|
- 6
|
156
183
|
version: 0.8.6
|
157
|
-
version_requirements: *
|
184
|
+
version_requirements: *id011
|
158
185
|
name: flexmock
|
159
186
|
prerelease: false
|
160
187
|
type: :development
|
161
188
|
- !ruby/object:Gem::Dependency
|
162
|
-
requirement: &
|
189
|
+
requirement: &id012 !ruby/object:Gem::Requirement
|
163
190
|
none: false
|
164
191
|
requirements:
|
165
192
|
- - ">="
|
@@ -168,12 +195,12 @@ dependencies:
|
|
168
195
|
segments:
|
169
196
|
- 0
|
170
197
|
version: "0"
|
171
|
-
version_requirements: *
|
198
|
+
version_requirements: *id012
|
172
199
|
name: memcache-client
|
173
200
|
prerelease: false
|
174
201
|
type: :development
|
175
202
|
- !ruby/object:Gem::Dependency
|
176
|
-
requirement: &
|
203
|
+
requirement: &id013 !ruby/object:Gem::Requirement
|
177
204
|
none: false
|
178
205
|
requirements:
|
179
206
|
- - ">="
|
@@ -182,12 +209,12 @@ dependencies:
|
|
182
209
|
segments:
|
183
210
|
- 0
|
184
211
|
version: "0"
|
185
|
-
version_requirements: *
|
212
|
+
version_requirements: *id013
|
186
213
|
name: rcov
|
187
214
|
prerelease: false
|
188
215
|
type: :development
|
189
216
|
- !ruby/object:Gem::Dependency
|
190
|
-
requirement: &
|
217
|
+
requirement: &id014 !ruby/object:Gem::Requirement
|
191
218
|
none: false
|
192
219
|
requirements:
|
193
220
|
- - ">="
|
@@ -196,12 +223,12 @@ dependencies:
|
|
196
223
|
segments:
|
197
224
|
- 0
|
198
225
|
version: "0"
|
199
|
-
version_requirements: *
|
226
|
+
version_requirements: *id014
|
200
227
|
name: rdoc
|
201
228
|
prerelease: false
|
202
229
|
type: :development
|
203
230
|
- !ruby/object:Gem::Dependency
|
204
|
-
requirement: &
|
231
|
+
requirement: &id015 !ruby/object:Gem::Requirement
|
205
232
|
none: false
|
206
233
|
requirements:
|
207
234
|
- - ">="
|
@@ -212,10 +239,66 @@ dependencies:
|
|
212
239
|
- 3
|
213
240
|
- 11
|
214
241
|
version: 2.3.11
|
215
|
-
version_requirements: *
|
242
|
+
version_requirements: *id015
|
216
243
|
name: activerecord
|
217
244
|
prerelease: false
|
218
245
|
type: :development
|
246
|
+
- !ruby/object:Gem::Dependency
|
247
|
+
requirement: &id016 !ruby/object:Gem::Requirement
|
248
|
+
none: false
|
249
|
+
requirements:
|
250
|
+
- - ">="
|
251
|
+
- !ruby/object:Gem::Version
|
252
|
+
hash: 3
|
253
|
+
segments:
|
254
|
+
- 0
|
255
|
+
version: "0"
|
256
|
+
version_requirements: *id016
|
257
|
+
name: vcr
|
258
|
+
prerelease: false
|
259
|
+
type: :development
|
260
|
+
- !ruby/object:Gem::Dependency
|
261
|
+
requirement: &id017 !ruby/object:Gem::Requirement
|
262
|
+
none: false
|
263
|
+
requirements:
|
264
|
+
- - ">="
|
265
|
+
- !ruby/object:Gem::Version
|
266
|
+
hash: 3
|
267
|
+
segments:
|
268
|
+
- 0
|
269
|
+
version: "0"
|
270
|
+
version_requirements: *id017
|
271
|
+
name: webmock
|
272
|
+
prerelease: false
|
273
|
+
type: :development
|
274
|
+
- !ruby/object:Gem::Dependency
|
275
|
+
requirement: &id018 !ruby/object:Gem::Requirement
|
276
|
+
none: false
|
277
|
+
requirements:
|
278
|
+
- - ">="
|
279
|
+
- !ruby/object:Gem::Version
|
280
|
+
hash: 3
|
281
|
+
segments:
|
282
|
+
- 0
|
283
|
+
version: "0"
|
284
|
+
version_requirements: *id018
|
285
|
+
name: pry
|
286
|
+
prerelease: false
|
287
|
+
type: :development
|
288
|
+
- !ruby/object:Gem::Dependency
|
289
|
+
requirement: &id019 !ruby/object:Gem::Requirement
|
290
|
+
none: false
|
291
|
+
requirements:
|
292
|
+
- - ">="
|
293
|
+
- !ruby/object:Gem::Version
|
294
|
+
hash: 3
|
295
|
+
segments:
|
296
|
+
- 0
|
297
|
+
version: "0"
|
298
|
+
version_requirements: *id019
|
299
|
+
name: pry-doc
|
300
|
+
prerelease: false
|
301
|
+
type: :development
|
219
302
|
description:
|
220
303
|
email: james@floppy.org.uk
|
221
304
|
executables:
|
@@ -230,15 +313,48 @@ files:
|
|
230
313
|
- Appraisals
|
231
314
|
- CHANGELOG.txt
|
232
315
|
- Gemfile
|
233
|
-
- Gemfile.lock
|
234
316
|
- LICENSE.txt
|
235
317
|
- README.txt
|
236
318
|
- Rakefile
|
237
319
|
- VERSION
|
238
320
|
- amee.example.yml
|
239
321
|
- amee.gemspec
|
322
|
+
- amee_test_credentials.example.yml
|
240
323
|
- bin/ameesh
|
241
324
|
- cacert.pem
|
325
|
+
- cassettes/AMEE_Connection/v2/raising_unhandled_errors.yml
|
326
|
+
- cassettes/AMEE_Connection/v3/retries/502.yml
|
327
|
+
- cassettes/AMEE_Connection/v3/retries/503.yml
|
328
|
+
- cassettes/AMEE_Connection/v3/retries/504.yml
|
329
|
+
- cassettes/AMEE_Connection/v3/retries/AMEE_TimeOut.yml
|
330
|
+
- cassettes/AMEE_Connection/v3/should_be_able_to_get_from_meta_server.yml
|
331
|
+
- cassettes/AMEE_Connection/v3/should_be_able_to_handle_failed_gets_from_meta_server.yml
|
332
|
+
- cassettes/AMEE_Connection/v3/should_be_able_to_post_to_meta_server.yml
|
333
|
+
- cassettes/AMEE_Connection/v3/should_have_a_connection_to_meta_server.yml
|
334
|
+
- cassettes/AMEE_Connection/v3/should_login_and_know_the_path_to_the_server.yml
|
335
|
+
- cassettes/AMEE_Connection_Caching_Off/authenticating.yml
|
336
|
+
- cassettes/AMEE_Connection_Caching_Off/first_request.yml
|
337
|
+
- cassettes/AMEE_Connection_Caching_Off/second_request.yml
|
338
|
+
- cassettes/AMEE_Connection_Caching_On/authenticating.yml
|
339
|
+
- cassettes/AMEE_Connection_Caching_On/first_request.yml
|
340
|
+
- cassettes/AMEE_Connection_Caching_clear_all/second_request.yml
|
341
|
+
- cassettes/AMEE_Connection_Caching_clear_manually/second_request.yml
|
342
|
+
- cassettes/AMEE_Connection_Caching_further_down_tree/second_request.yml
|
343
|
+
- cassettes/AMEE_Connection_with_authentication/handling_404s.yml
|
344
|
+
- cassettes/AMEE_Connection_with_authentication/hitting_private_urls.yml
|
345
|
+
- cassettes/AMEE_Connection_with_authentication/raising_errors_if_permission_denied.yml
|
346
|
+
- cassettes/AMEE_Connection_with_authentication/should_re-authenticate_and_refresh_authtoken_when_authtoken_expires.yml
|
347
|
+
- cassettes/AMEE_Connection_with_authentication/should_refresh_authtoken_when_authtoken_is_changed.yml
|
348
|
+
- cassettes/AMEE_Connection_with_authentication/using_a_v1_key.yml
|
349
|
+
- cassettes/AMEE_Connection_with_authentication/using_a_v2_key/detects_the_API_version_for_JSON.yml
|
350
|
+
- cassettes/AMEE_Connection_with_authentication/using_a_v2_key/detects_the_API_version_for_XML.yml
|
351
|
+
- cassettes/AMEE_Connection_with_authentication_doing_write-requests.yml
|
352
|
+
- cassettes/AMEE_Connection_with_authentication_doing_write-requests/working_with_an_existing_profile/deleting_existing_items.yml
|
353
|
+
- cassettes/AMEE_Connection_with_authentication_doing_write-requests/working_with_an_existing_profile/sending_updates_to_existing_items.yml
|
354
|
+
- cassettes/AMEE_Connection_with_bad_authentication_information/hitting_a_private_url.yml
|
355
|
+
- cassettes/AMEE_Connection_with_bad_authentication_information/hitting_a_public_url.yml
|
356
|
+
- cassettes/AMEE_Connection_with_incorrect_server_name.yml
|
357
|
+
- cassettes/AMEE_Connection_with_retry_enabled.yml
|
242
358
|
- examples/create_profile.rb
|
243
359
|
- examples/create_profile_item.rb
|
244
360
|
- examples/list_profiles.rb
|
data/Gemfile.lock
DELETED
@@ -1,63 +0,0 @@
|
|
1
|
-
GEM
|
2
|
-
remote: http://rubygems.org/
|
3
|
-
specs:
|
4
|
-
activemodel (3.1.1)
|
5
|
-
activesupport (= 3.1.1)
|
6
|
-
builder (~> 3.0.0)
|
7
|
-
i18n (~> 0.6)
|
8
|
-
activerecord (3.1.1)
|
9
|
-
activemodel (= 3.1.1)
|
10
|
-
activesupport (= 3.1.1)
|
11
|
-
arel (~> 2.2.1)
|
12
|
-
tzinfo (~> 0.3.29)
|
13
|
-
activesupport (3.1.1)
|
14
|
-
multi_json (~> 1.0)
|
15
|
-
appraisal (0.4.0)
|
16
|
-
bundler
|
17
|
-
rake
|
18
|
-
arel (2.2.1)
|
19
|
-
builder (3.0.0)
|
20
|
-
diff-lcs (1.1.3)
|
21
|
-
flexmock (0.9.0)
|
22
|
-
git (1.2.5)
|
23
|
-
i18n (0.6.0)
|
24
|
-
jeweler (1.6.4)
|
25
|
-
bundler (~> 1.0)
|
26
|
-
git (>= 1.2.5)
|
27
|
-
rake
|
28
|
-
json (1.6.1)
|
29
|
-
log4r (1.1.9)
|
30
|
-
memcache-client (1.8.5)
|
31
|
-
multi_json (1.0.3)
|
32
|
-
nokogiri (1.4.7)
|
33
|
-
rake (0.9.2.2)
|
34
|
-
rcov (0.9.11)
|
35
|
-
rdoc (3.11)
|
36
|
-
json (~> 1.4)
|
37
|
-
rspec (2.6.0)
|
38
|
-
rspec-core (~> 2.6.0)
|
39
|
-
rspec-expectations (~> 2.6.0)
|
40
|
-
rspec-mocks (~> 2.6.0)
|
41
|
-
rspec-core (2.6.4)
|
42
|
-
rspec-expectations (2.6.0)
|
43
|
-
diff-lcs (~> 1.1.2)
|
44
|
-
rspec-mocks (2.6.0)
|
45
|
-
tzinfo (0.3.30)
|
46
|
-
|
47
|
-
PLATFORMS
|
48
|
-
ruby
|
49
|
-
|
50
|
-
DEPENDENCIES
|
51
|
-
activerecord (>= 2.3.11)
|
52
|
-
activesupport (>= 2.3.11)
|
53
|
-
appraisal
|
54
|
-
bundler (~> 1.0.0)
|
55
|
-
flexmock (> 0.8.6)
|
56
|
-
jeweler (~> 1.6.4)
|
57
|
-
json
|
58
|
-
log4r
|
59
|
-
memcache-client
|
60
|
-
nokogiri (~> 1.4.4)
|
61
|
-
rcov
|
62
|
-
rdoc
|
63
|
-
rspec (= 2.6.0)
|