soaspec 0.0.53 → 0.0.54
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/ChangeLog +4 -0
- data/Gemfile.lock +1 -1
- data/lib/soaspec/exchange_handlers/rest_handler.rb +15 -0
- data/lib/soaspec/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a989b94a49f1bd84e619031834373e765c66b143
|
4
|
+
data.tar.gz: 28fb2b5ea4a7dfd871c4c354049c4ec969f925e1
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: f62f593a34c8065c71c1b23859e1e9df425c300420472b95a5bc68cba0967569ae2ef2184b9ee658320e79ca767cd9706149155179380f330d122e8824594a82
|
7
|
+
data.tar.gz: 6ad9ca4d1435e026a1f9b7ce3d283625cf29f599e7df9d6f101bad7844f80601b9716cee3c0f1492eb959abe99e1080c1bfdbf002b8496ddb3299f6e3ab3da92
|
data/ChangeLog
CHANGED
data/Gemfile.lock
CHANGED
@@ -86,6 +86,13 @@ module Soaspec
|
|
86
86
|
oauth2 **oauth_hash
|
87
87
|
end
|
88
88
|
|
89
|
+
# @param [Hash] headers Hash of REST headers used in RestClient
|
90
|
+
def headers(headers)
|
91
|
+
define_method('rest_client_headers') do
|
92
|
+
headers
|
93
|
+
end
|
94
|
+
end
|
95
|
+
|
89
96
|
end
|
90
97
|
|
91
98
|
# Wraps around Savon client defining default values dependent on the soap request
|
@@ -102,8 +109,14 @@ module Soaspec
|
|
102
109
|
nil
|
103
110
|
end
|
104
111
|
|
112
|
+
# Headers used in RestClient
|
113
|
+
def rest_client_headers
|
114
|
+
{}
|
115
|
+
end
|
116
|
+
|
105
117
|
# Add values to here when extending this class to have default REST options.
|
106
118
|
# See rest client resource at https://github.com/rest-client/rest-client for details
|
119
|
+
# It's easier to set headers via 'headers' accessor rather than here
|
107
120
|
# @return [Hash] Options adding to & overriding defaults
|
108
121
|
def rest_resource_options
|
109
122
|
{
|
@@ -122,6 +135,8 @@ module Soaspec
|
|
122
135
|
super
|
123
136
|
set_remove_key(options, :default_hash)
|
124
137
|
merged_options = rest_resource_options
|
138
|
+
merged_options[:headers] ||= {}
|
139
|
+
merged_options[:headers].merge! rest_client_headers
|
125
140
|
merged_options.merge!(options)
|
126
141
|
@resource = RestClient::Resource.new(base_url_value, merged_options) # @resource[url_extension].get
|
127
142
|
end
|
data/lib/soaspec/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: soaspec
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.54
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- SamuelGarrattIQA
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2018-05-
|
11
|
+
date: 2018-05-06 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|