docusigner 0.0.5 → 0.0.6
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/docusigner.gemspec +1 -1
- data/lib/docusigner/envelope.rb +6 -0
- data/test/unit/envelope_test.rb +14 -0
- 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: 4f4ba241cd3e624d97a3444ae8535160a71a8d7d
|
4
|
+
data.tar.gz: 3ae9fe3760d8c6ee61833663e2fde646da6289c6
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b268e71836b42dbcc4c8ea8e83f7cf99a88312e566874a40d4eaff89bc1383e49ebe1efac22e51bec940d04b3bc43605bd71b75c86686c71e7eb2280d394e3d2
|
7
|
+
data.tar.gz: b461b9e98352b1c587577572fb1a07974db5678db99fae01dd5048b7ca5e2d8856ffab898c2baabd35db9d4816cca2225b8a56b8e2b3f1124564c5a1dc6b4ef7
|
data/docusigner.gemspec
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
Gem::Specification.new do |s|
|
2
2
|
s.name = "docusigner"
|
3
|
-
s.version = "0.0.
|
3
|
+
s.version = "0.0.6"
|
4
4
|
s.description = "Unofficial gem for accessing the DocuSign REST API"
|
5
5
|
s.summary = "Unofficial gem for accessing the DocuSign REST API"
|
6
6
|
s.add_dependency "reactive_resource", ">= 0.7.3"
|
data/lib/docusigner/envelope.rb
CHANGED
@@ -28,6 +28,12 @@ module Docusigner
|
|
28
28
|
resp = post("#{id}/views/recipient", prefix_options, params.to_json)
|
29
29
|
format.decode(resp.body)
|
30
30
|
end
|
31
|
+
|
32
|
+
# fetch documents - don't use helper b/c we don't want to try to parse as json
|
33
|
+
def documents_combined(id, prefix_options = {})
|
34
|
+
connection.get(custom_method_collection_url("#{id}/documents/combined", prefix_options), headers).body
|
35
|
+
end
|
36
|
+
|
31
37
|
end
|
32
38
|
|
33
39
|
def send!
|
data/test/unit/envelope_test.rb
CHANGED
@@ -157,6 +157,20 @@ class Docusigner::EnvelopeTest < Test::Unit::TestCase
|
|
157
157
|
assert_requested(:post, "https://demo.docusign.net/restapi/v2/accounts/1234-asdf/envelopes/qwer-7890/views/correct.json")
|
158
158
|
assert_equal("http://localhost/someurl", url)
|
159
159
|
end
|
160
|
+
|
161
|
+
should "be able to get the combined pdf" do
|
162
|
+
stub_request(:get, "https://demo.docusign.net/restapi/v2/accounts/1234-asdf/envelopes/qwer-7890/documents/combined.json")
|
163
|
+
.to_return(:body => "pdf goes here")
|
164
|
+
assert_equal("pdf goes here", @envelope.documents_combined)
|
165
|
+
assert_requested(:get, "https://demo.docusign.net/restapi/v2/accounts/1234-asdf/envelopes/qwer-7890/documents/combined.json")
|
166
|
+
end
|
167
|
+
|
168
|
+
should "be able to get the combined pdf using class method" do
|
169
|
+
stub_request(:get, "https://demo.docusign.net/restapi/v2/accounts/1234-asdf/envelopes/qwer-7890/documents/combined.json")
|
170
|
+
.to_return(:body => "pdf goes here")
|
171
|
+
assert_equal("pdf goes here", Docusigner::Envelope.documents_combined(@envelope.id, @envelope.prefix_options))
|
172
|
+
assert_requested(:get, "https://demo.docusign.net/restapi/v2/accounts/1234-asdf/envelopes/qwer-7890/documents/combined.json")
|
173
|
+
end
|
160
174
|
end
|
161
175
|
|
162
176
|
end
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: docusigner
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.6
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Jeff Ching
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2013-07-
|
11
|
+
date: 2013-07-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: reactive_resource
|