caseblocks_api 0.2.6 → 0.2.8
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.
- data/README.rdoc +1 -1
- data/VERSION +1 -1
- data/caseblocks_api.gemspec +3 -3
- data/lib/caseblocks_api/finder.rb +1 -1
- data/spec/lib/caseblocks_api/find_case_by_property_spec.rb +1 -1
- data/spec/support/fake_http_party.rb +5 -0
- metadata +4 -4
data/README.rdoc
CHANGED
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.2.
|
1
|
+
0.2.8
|
data/caseblocks_api.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = "caseblocks_api"
|
8
|
-
s.version = "0.2.
|
8
|
+
s.version = "0.2.8"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
11
|
s.authors = ["Mark Provan"]
|
12
|
-
s.date = "
|
12
|
+
s.date = "2013-01-11"
|
13
13
|
s.email = "development@emergeadapt.com"
|
14
14
|
s.extra_rdoc_files = [
|
15
15
|
"LICENSE.txt",
|
@@ -41,7 +41,7 @@ Gem::Specification.new do |s|
|
|
41
41
|
s.homepage = "http://github.com/EmergeAdapt/caseblocks_api"
|
42
42
|
s.licenses = ["MIT"]
|
43
43
|
s.require_paths = ["lib"]
|
44
|
-
s.rubygems_version = "1.8.
|
44
|
+
s.rubygems_version = "1.8.24"
|
45
45
|
s.summary = "Ruby wrapper for CaseBlocks API"
|
46
46
|
|
47
47
|
if s.respond_to? :specification_version then
|
@@ -12,7 +12,7 @@ module CaseblocksAPI
|
|
12
12
|
end
|
13
13
|
|
14
14
|
def execute_multiple(case_type, properties)
|
15
|
-
@client.
|
15
|
+
@client.post("/case_blocks/#{case_type}", :body => {search: true, properties: properties}.to_json)
|
16
16
|
end
|
17
17
|
end
|
18
18
|
|
@@ -21,7 +21,7 @@ describe CaseblocksAPI::Finder do
|
|
21
21
|
Given (:find_by_properties) { CaseblocksAPI::Finder.new(client) }
|
22
22
|
When (:result) { find_by_properties.execute_multiple(case_type, properties) }
|
23
23
|
Then { expect(client.requested_url).to eql "/case_blocks/#{case_type}" }
|
24
|
-
Then { expect(client.params).to eql({
|
24
|
+
Then { expect(client.params).to eql({body: {search: true, properties: properties}.to_json}) }
|
25
25
|
end
|
26
26
|
|
27
27
|
end
|
@@ -1,11 +1,16 @@
|
|
1
1
|
class FakeHttpParty
|
2
2
|
attr_reader :requested_url, :params
|
3
|
+
|
3
4
|
def get(url, params={})
|
4
5
|
@requested_url = url
|
5
6
|
@params = params
|
6
7
|
result
|
7
8
|
end
|
8
9
|
|
10
|
+
def post(url, params={})
|
11
|
+
get(url, params)
|
12
|
+
end
|
13
|
+
|
9
14
|
def put(url, params)
|
10
15
|
@requested_url = url
|
11
16
|
@params = params
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: caseblocks_api
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.2.
|
4
|
+
version: 0.2.8
|
5
5
|
prerelease:
|
6
6
|
platform: ruby
|
7
7
|
authors:
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date:
|
12
|
+
date: 2013-01-11 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: httparty
|
@@ -215,7 +215,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
|
|
215
215
|
version: '0'
|
216
216
|
segments:
|
217
217
|
- 0
|
218
|
-
hash: -
|
218
|
+
hash: -1573686528482834911
|
219
219
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
220
220
|
none: false
|
221
221
|
requirements:
|
@@ -224,7 +224,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
224
224
|
version: '0'
|
225
225
|
requirements: []
|
226
226
|
rubyforge_project:
|
227
|
-
rubygems_version: 1.8.
|
227
|
+
rubygems_version: 1.8.24
|
228
228
|
signing_key:
|
229
229
|
specification_version: 3
|
230
230
|
summary: Ruby wrapper for CaseBlocks API
|