meducation_sdk 0.3.3 → 0.3.4

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,15 +1,15 @@
1
1
  ---
2
2
  !binary "U0hBMQ==":
3
3
  metadata.gz: !binary |-
4
- YThiZjJhNDY5YWUxNDZhZjBmNThkOWYzN2FiMGFhMjY4OWUyMDBmYQ==
4
+ OTIxZTg2MmU3ZGFlOWZiYmNkODRiN2IzMDBlMWVhYjIyM2JiOTU2YQ==
5
5
  data.tar.gz: !binary |-
6
- ZmI2NGM1YWJlZTMzNDczNzU5NmQ0MDc4NGJhMTYzMzAzZjNmMjRlOA==
6
+ YTRjZmE4MjAxZjRkMjM5YWE0ZjY5MTQyOTcyNWUxN2I4M2RiNjlmMA==
7
7
  SHA512:
8
8
  metadata.gz: !binary |-
9
- MGQ0NjMzN2RmODg0ZTYzNzYxMzI3ZjAwZWE1NzEzNjUzMzViZGQyZTg2ZGUy
10
- NGI3NDQxNWE4MWI5ZTYzOTRjYjViYzZmZGNkYWUyZGYwMGJhMjQ4NjMxZmVj
11
- ZGY2YTg2OGFiYTBjNjRkNWQyOTA2M2M5MTQ1MWNiNTVhZTMzYzQ=
9
+ MGM0ZjM3MDA3YjA0ZDIzYTY4MmY2OWU1NGJkZTIyNTJmNjY0NmM2MzA0M2Jh
10
+ ZjE3ZjVjMjgyODYzYzgxYzc0OWQ5MGUwYTNkZjZhZWVkNmZjMzllZGI3YzI5
11
+ ZTEwOGQ1ODhmOGYzYzhjNDRkMWJjOTI2OGYzYjc5MWZhNjYxY2Y=
12
12
  data.tar.gz: !binary |-
13
- ZDhlYTk2M2Q1ZDk4ZTQxNWRlYTNlNTEyZGUwMDMxNDFlNTRhYTY3ZThmZDE5
14
- NjMyYjVkNmVmNjgxYTE3YjdlNmEwNjFhOTg1ZmYyOTA5NWVkZTQ5MTczMGM4
15
- MDcwODg5NTdjYTdmOTE3NTM2ZTdjMzk5MTE3MWFiNzg1ZjMyNmY=
13
+ NTE0MGY5YTJkNWFiZDFjYjhjNGFhZTFhOWZmNDQxNGE4MDE1YWVmYjY2OTY5
14
+ N2Y4YTZiNmM4MTc4YjIxMWJjYTEyZjc0MTBmYWRkMmFkYjFiOTM1YmU1ZjA1
15
+ MDFkZTQ5NTQ5NDI0YTFmNWI5ZDgzMGE1MzlhMDBmNzY5ZGU0NDQ=
@@ -1,3 +1,7 @@
1
+ # 0.3.4 / 2013-12-13
2
+ * [FEATURE] Upgrade to latest loquor to support caching
3
+ * [BUG FIX] Fixed loading of mesh_heading parents.
4
+
1
5
  # 0.3.3 / 2013-12-11
2
6
  * [BUG FIX] Fixed mesh_heading path.
3
7
 
@@ -16,7 +16,7 @@ module MeducationSDK
16
16
  self.logger = Filum.logger
17
17
  end
18
18
 
19
- [:access_id, :secret_key, :endpoint].each do |setting|
19
+ [:access_id, :secret_key, :endpoint, :cache].each do |setting|
20
20
  define_method "#{setting}=" do |val|
21
21
  Loquor.config.send("#{setting}=", val)
22
22
  end
@@ -3,7 +3,11 @@ module MeducationSDK
3
3
  self.path = "/mesh_headings"
4
4
 
5
5
  def parents
6
- MeshHeading.where(id: parent_ids)
6
+ parent_ids.map { |p_id| MeshHeading.find(p_id) }
7
+ end
8
+
9
+ def parent_ids
10
+ @data[:parents].map { |p| p['id'] }
7
11
  end
8
12
  end
9
13
 
@@ -1,3 +1,3 @@
1
1
  module MeducationSDK
2
- VERSION = "0.3.3"
2
+ VERSION = "0.3.4"
3
3
  end
@@ -19,7 +19,7 @@ Gem::Specification.new do |spec|
19
19
  spec.require_paths = ["lib"]
20
20
 
21
21
  spec.add_dependency "activesupport", '~> 3.2.15'
22
- spec.add_dependency "loquor", '~> 0.5.1'
22
+ spec.add_dependency "loquor", '~> 0.5.4'
23
23
 
24
24
  spec.add_development_dependency "bundler", "~> 1.3"
25
25
  spec.add_development_dependency "rake"
@@ -26,9 +26,21 @@ module MeducationSDK
26
26
  end
27
27
 
28
28
  def test_access_id_proxies_to_loquor
29
- access_id = "test-access-key"
29
+ access_id = "test-access-id"
30
30
  MeducationSDK.config.access_id = access_id
31
31
  assert_equal access_id, Loquor.config.access_id
32
32
  end
33
+
34
+ def test_secret_key_proxies_to_loquor
35
+ key = "test-secret-key"
36
+ MeducationSDK.config.secret_key = key
37
+ assert_equal key, Loquor.config.secret_key
38
+ end
39
+
40
+ def test_cache_proxies_to_loquor
41
+ cache = mock()
42
+ MeducationSDK.config.cache = cache
43
+ assert_equal cache, Loquor.config.cache
44
+ end
33
45
  end
34
46
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: meducation_sdk
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.3
4
+ version: 0.3.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jeremy Walker
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-12-11 00:00:00.000000000 Z
11
+ date: 2013-12-13 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: activesupport
@@ -30,14 +30,14 @@ dependencies:
30
30
  requirements:
31
31
  - - ~>
32
32
  - !ruby/object:Gem::Version
33
- version: 0.5.1
33
+ version: 0.5.4
34
34
  type: :runtime
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
38
  - - ~>
39
39
  - !ruby/object:Gem::Version
40
- version: 0.5.1
40
+ version: 0.5.4
41
41
  - !ruby/object:Gem::Dependency
42
42
  name: bundler
43
43
  requirement: !ruby/object:Gem::Requirement
@@ -192,3 +192,4 @@ test_files:
192
192
  - test/resources/mesh_heading_test.rb
193
193
  - test/resources/user_test.rb
194
194
  - test/test_helper.rb
195
+ has_rdoc: