summaryrefslogtreecommitdiff
path: root/spec/unit/puppet
diff options
context:
space:
mode:
authorBryan Jen <bryan.jen@gmail.com>2015-09-14 09:47:27 -0700
committerBryan Jen <bryan.jen@gmail.com>2015-09-14 09:47:27 -0700
commitf0d087a1cbf99228b9edb3e1d2e28d81df794e24 (patch)
treed71e709dcf31f43f56d9220f349fc976705e437d /spec/unit/puppet
parenta39349a4388cd56aad5cfc8eead2f2a17f545287 (diff)
parent7758331f503a9198921362761079cbfd941c625e (diff)
downloadpuppet-vcsrepo-f0d087a1cbf99228b9edb3e1d2e28d81df794e24.tar.gz
puppet-vcsrepo-f0d087a1cbf99228b9edb3e1d2e28d81df794e24.tar.bz2
Merge pull request #269 from monai/develop
Add feature 'depth' and parameter 'trust_server_cert' to svn
Diffstat (limited to 'spec/unit/puppet')
-rw-r--r--spec/unit/puppet/provider/vcsrepo/svn_spec.rb22
1 files changed, 22 insertions, 0 deletions
diff --git a/spec/unit/puppet/provider/vcsrepo/svn_spec.rb b/spec/unit/puppet/provider/vcsrepo/svn_spec.rb
index 77f0e03..25951bd 100644
--- a/spec/unit/puppet/provider/vcsrepo/svn_spec.rb
+++ b/spec/unit/puppet/provider/vcsrepo/svn_spec.rb
@@ -52,6 +52,28 @@ describe Puppet::Type.type(:vcsrepo).provider(:svn) do
provider.create
end
end
+
+ context "with depth" do
+ it "should execute 'svn checkout' with a depth" do
+ resource[:source] = 'exists'
+ resource[:depth] = 'infinity'
+ provider.expects(:svn).with('--non-interactive', 'checkout', '--depth', 'infinity',
+ resource.value(:source),
+ resource.value(:path))
+ provider.create
+ end
+ end
+
+ context "with trust_server_cert" do
+ it "should execute 'svn checkout' with a trust-server-cert" do
+ resource[:source] = 'exists'
+ resource[:trust_server_cert] = true
+ provider.expects(:svn).with('--non-interactive', '--trust-server-cert', 'checkout',
+ resource.value(:source),
+ resource.value(:path))
+ provider.create
+ end
+ end
end
describe 'destroying' do