spec/hello_sign/api/template_spec.rb in hellosign-ruby-sdk-3.6.4 vs spec/hello_sign/api/template_spec.rb in hellosign-ruby-sdk-3.7.0
- old
+ new
@@ -9,10 +9,14 @@
it 'should get the correct resource' do
expect(a_get('/template/1')).to have_been_made
end
+ it 'should return response headers' do
+ expect(@template.headers).to_not be_nil
+ end
+
it 'should return a Template' do
expect(@template).to be_an HelloSign::Resource::Template
end
end
@@ -24,10 +28,14 @@
it 'should get the correct resource' do
expect(a_get('/template/list')).to have_been_made
end
+ it 'returns reponse headers' do
+ expect(@template.headers).to_not be_nil
+ end
+
it 'should return a ResourceArray' do
expect(@template).to be_an HelloSign::Resource::ResourceArray
end
it 'each of Array is an Template' do
@@ -51,10 +59,14 @@
it 'should get the correct resource' do
expect(a_post('/template/add_user/1')).to have_been_made
end
+ it 'should return response headers' do
+ expect(@template.headers).to_not be_nil
+ end
+
it 'should return a Template' do
expect(@template).to be_an HelloSign::Resource::Template
end
end
@@ -66,10 +78,14 @@
it 'should get the correct resource' do
expect(a_post('/template/remove_user/1')).to have_been_made
end
+ it 'should return response headers' do
+ expect(@template.headers).to_not be_nil
+ end
+
it 'should return a Template' do
expect(@template).to be_an HelloSign::Resource::Template
end
end
@@ -80,10 +96,14 @@
end
it 'should get the correct resource' do
expect(a_get('/template/files/1')).to have_been_made
end
+
+ it 'should return response headers' do
+ expect(@files[:headers]).to_not be_nil
+ end
end
describe '#get_template_files with options' do
describe ':get_url' do
before do
@@ -92,10 +112,14 @@
end
it 'should get the correct resource' do
expect(a_get('/template/files/1?get_url=true')).to have_been_made
end
+
+ it 'should return response headers' do
+ expect(@files[:headers]).to_not be_nil
+ end
end
describe ':file_type' do
before do
stub_get('/template/files/1?file_type=pdf', 'file')
@@ -103,10 +127,14 @@
end
it 'should get the correct resource' do
expect(a_get('/template/files/1?file_type=pdf')).to have_been_made
end
+
+ it 'should return response headers' do
+ expect(@files[:headers]).to_not be_nil
+ end
end
describe ':file_type and :get_url' do
before do
stub_get('/template/files/1?file_type=pdf&get_url=true', 'file')
@@ -114,10 +142,14 @@
end
it 'should get the correct resource' do
expect(a_get('/template/files/1?file_type=pdf&get_url=true')).to have_been_made
end
+
+ it 'should return response headers' do
+ expect(@files[:headers]).to_not be_nil
+ end
end
end
describe '#update_template_files' do
before do
@@ -129,8 +161,12 @@
expect(@template).to be_an HelloSign::Resource::Template
end
it 'should get the correct resource' do
expect(a_post('/template/update_files/1')).to have_been_made
+ end
+
+ it 'should return response headers' do
+ expect(@template.headers).to_not be_nil
end
end
end