allscripts_unity_client 3.2.1 → 3.2.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8b4d1d0ec579e0cc563c6da328ba213ec4c248ac
4
- data.tar.gz: 9803794fa5de5d1790618c35dbd56782274b6550
3
+ metadata.gz: 93d6a293357813026811d3ac5218a18f6670891f
4
+ data.tar.gz: 31e812dd2336a1365a453b5156e8caeed5f8f508
5
5
  SHA512:
6
- metadata.gz: e33b37029cfa5e5c31cae06efb481cb0dd8df686aa2005b2a8c348838f3fe0d64e410423da02e79cde619e5ae603d52aa85a624f95823c8a42921aa5928a3c3f
7
- data.tar.gz: beb19b25e227b2d5608371d4669b766ad5ac66b03d7d08637a95d47b58a1317e3db21a86e1a88936202ea9d3387aeb2222b94214c6590b609cb8c1261691d306
6
+ metadata.gz: 106616676750288be5c91e4ca7a8c45137e8b05d63601a7bc4274bc474afde5e624c4a55f08134a519f0a0e0423cec299955c981f249bad74a3cd0f18dc0b30f
7
+ data.tar.gz: 016876031b97295407002e4fb1a61e78dec615855c944cd0f8433eb4c847923b165835cb45dee4509308a968b3820e823ef8525086d849ce2ef58f25c07231eb
data/.travis.yml CHANGED
@@ -3,7 +3,11 @@ rvm:
3
3
  - 1.9.3
4
4
  - 2.0.0
5
5
  - 2.1.2
6
-
6
+ - 2.2.2
7
+ before_install:
8
+ - gem update --system
9
+ - gem update bundler
10
+ - gem cleanup bundler
7
11
  install:
8
12
  - "gem install bundler"
9
13
  - "bundle install --jobs=3 --retry=3"
@@ -23,7 +23,7 @@ Gem::Specification.new do |gem|
23
23
  gem.files = `git ls-files`.split("\n").delete_if { |file| /^\.ruby-version$/.match(file) }
24
24
 
25
25
  gem.add_dependency 'httpclient', '~> 2.6'
26
- gem.add_dependency 'activesupport', '>= 3'
26
+ gem.add_dependency 'activesupport', '>=3', '< 5'
27
27
  gem.add_dependency 'nokogiri', '>= 1.4.0'
28
28
  gem.add_dependency 'nori', '~> 2.4.0'
29
29
  gem.add_dependency 'american_date', '~> 1.1.0'
@@ -48,16 +48,20 @@ module AllscriptsUnityClient
48
48
  end
49
49
 
50
50
  def magic(parameters = {})
51
- request_data = JSONUnityRequest.new(parameters, @options.timezone, @options.appname, @security_token)
51
+ request = JSONUnityRequest.new(parameters, @options.timezone, @options.appname, @security_token)
52
+ log_magic(request)
53
+
54
+ request_hash = request.to_hash
55
+ log_info("Request Data: #{request_hash}")
56
+ request_data = MultiJson.dump(request_hash)
52
57
 
53
58
  start_timer
54
- response = @connection.post(build_uri('MagicJson'), MultiJson.dump(request_data.to_hash))
59
+ response = @connection.post(build_uri('MagicJson'), request_data)
60
+ log_info("Response Status: #{response.status}")
55
61
  end_timer
56
62
 
57
63
  response = MultiJson.load(response.body)
58
-
59
64
  raise_if_response_error(response)
60
- log_magic(request_data)
61
65
 
62
66
  response = JSONUnityResponse.new(response, @options.timezone)
63
67
  response.to_hash
@@ -1,3 +1,3 @@
1
1
  module AllscriptsUnityClient
2
- VERSION = '3.2.1'
2
+ VERSION = '3.2.2'
3
3
  end
@@ -46,6 +46,7 @@ describe AllscriptsUnityClient::JSONClientDriver do
46
46
  allow(subject).to receive(:start_timer)
47
47
  allow(subject).to receive(:end_timer)
48
48
  allow(subject).to receive(:log_magic)
49
+ allow(subject).to receive(:log_info).twice
49
50
  end
50
51
 
51
52
  it 'should POST to /Unity/UnityService.svc/json/MagicJson' do
@@ -78,6 +79,11 @@ describe AllscriptsUnityClient::JSONClientDriver do
78
79
  subject.magic
79
80
  expect(subject).to have_received(:log_magic)
80
81
  end
82
+
83
+ it 'should call log_info for recording request data and response status' do
84
+ subject.magic
85
+ expect(subject).to have_received(:log_info).twice
86
+ end
81
87
  end
82
88
 
83
89
  describe '#get_security_token!' do
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: allscripts_unity_client
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.2.1
4
+ version: 3.2.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - healthfinch
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-04-12 00:00:00.000000000 Z
11
+ date: 2016-07-11 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: httpclient
@@ -31,6 +31,9 @@ dependencies:
31
31
  - - ">="
32
32
  - !ruby/object:Gem::Version
33
33
  version: '3'
34
+ - - "<"
35
+ - !ruby/object:Gem::Version
36
+ version: '5'
34
37
  type: :runtime
35
38
  prerelease: false
36
39
  version_requirements: !ruby/object:Gem::Requirement
@@ -38,6 +41,9 @@ dependencies:
38
41
  - - ">="
39
42
  - !ruby/object:Gem::Version
40
43
  version: '3'
44
+ - - "<"
45
+ - !ruby/object:Gem::Version
46
+ version: '5'
41
47
  - !ruby/object:Gem::Dependency
42
48
  name: nokogiri
43
49
  requirement: !ruby/object:Gem::Requirement
@@ -282,7 +288,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
282
288
  version: '0'
283
289
  requirements: []
284
290
  rubyforge_project:
285
- rubygems_version: 2.4.6
291
+ rubygems_version: 2.2.2
286
292
  signing_key:
287
293
  specification_version: 4
288
294
  summary: Allscripts Unity API client