diff options
author | Micah <micah@leap.se> | 2016-07-12 16:46:26 -0400 |
---|---|---|
committer | Micah <micah@leap.se> | 2016-07-12 16:46:26 -0400 |
commit | 850a14b59444737f703686d0d1996bf09ab08e2b (patch) | |
tree | 6d67b59126fc9d8329b6acdd072b53b5ea35bc25 /puppet/modules/vcsrepo/spec/acceptance/remove_repo_spec_noop.rb | |
parent | 5247b7ccf5b5889ee16262dd976b03047e34e32c (diff) |
git subrepo clone https://leap.se/git/puppet_vcsrepo puppet/modules/vcsrepo
subrepo:
subdir: "puppet/modules/vcsrepo"
merged: "4e23209"
upstream:
origin: "https://leap.se/git/puppet_vcsrepo"
branch: "master"
commit: "4e23209"
git-subrepo:
version: "0.3.0"
origin: "https://github.com/ingydotnet/git-subrepo"
commit: "1e79595"
Change-Id: I72f8ecdef4855ef9da6e1486453b1cdf01bb54a3
Diffstat (limited to 'puppet/modules/vcsrepo/spec/acceptance/remove_repo_spec_noop.rb')
-rw-r--r-- | puppet/modules/vcsrepo/spec/acceptance/remove_repo_spec_noop.rb | 31 |
1 files changed, 31 insertions, 0 deletions
diff --git a/puppet/modules/vcsrepo/spec/acceptance/remove_repo_spec_noop.rb b/puppet/modules/vcsrepo/spec/acceptance/remove_repo_spec_noop.rb new file mode 100644 index 00000000..f6bd86e9 --- /dev/null +++ b/puppet/modules/vcsrepo/spec/acceptance/remove_repo_spec_noop.rb @@ -0,0 +1,31 @@ +require 'spec_helper_acceptance' + +tmpdir = default.tmpdir('vcsrepo') + +describe 'does not remove a repo if noop' do + it 'creates a blank repo' do + pp = <<-EOS + vcsrepo { "#{tmpdir}/testrepo_noop_deleted": + ensure => present, + provider => git, + } + EOS + apply_manifest(pp, :catch_failures => true) + end + + it 'does not remove a repo if noop' do + pp = <<-EOS + vcsrepo { "#{tmpdir}/testrepo_noop_deleted": + ensure => absent, + provider => git, + force => true, + } + EOS + + apply_manifest(pp, :catch_failures => true, :noop => true, :verbose => false) + end + + describe file("#{tmpdir}/testrepo_noop_deleted") do + it { is_expected.to be_directory } + end +end |