mirror of
https://github.com/krislamo/puppet-rsnapshot
synced 2024-12-16 09:40:35 +00:00
add basic tests
This commit is contained in:
parent
03c73285ca
commit
09b6b4431c
3
.bundle/config
Normal file
3
.bundle/config
Normal file
@ -0,0 +1,3 @@
|
|||||||
|
---
|
||||||
|
BUNDLE_PATH: vendor/bundle
|
||||||
|
BUNDLE_DISABLE_SHARED_GEMS: '1'
|
@ -1,5 +1,8 @@
|
|||||||
fixtures:
|
fixtures:
|
||||||
repositories:
|
forge_modules:
|
||||||
"stdlib": "git://github.com/puppetlabs/puppetlabs-stdlib.git"
|
stdlib:
|
||||||
|
repo: "puppetlabs/stdlib"
|
||||||
|
epel:
|
||||||
|
repo: "stahnma/epel"
|
||||||
symlinks:
|
symlinks:
|
||||||
"rsnapshot": "#{source_dir}"
|
"rsnapshot": "#{source_dir}"
|
||||||
|
@ -14,9 +14,7 @@ class rsnapshot (
|
|||||||
$package_ensure = $rsnapshot::params::package_ensure,
|
$package_ensure = $rsnapshot::params::package_ensure,
|
||||||
$cron = $rsnapshot::params::cron,
|
$cron = $rsnapshot::params::cron,
|
||||||
) inherits rsnapshot::params {
|
) inherits rsnapshot::params {
|
||||||
if $puppetversion =~ /^(1|2|3)/ {
|
|
||||||
fail('This module requires Puppet 4')
|
|
||||||
}
|
|
||||||
if $hosts {
|
if $hosts {
|
||||||
class { '::rsnapshot::install': }->
|
class { '::rsnapshot::install': }->
|
||||||
class { '::rsnapshot::config': }
|
class { '::rsnapshot::config': }
|
||||||
|
@ -2,6 +2,4 @@ require 'spec_helper'
|
|||||||
describe 'rsnapshot' do
|
describe 'rsnapshot' do
|
||||||
it { should contain_class('rsnapshot::params') }
|
it { should contain_class('rsnapshot::params') }
|
||||||
it { is_expected.to compile }
|
it { is_expected.to compile }
|
||||||
it { is_expected.to contain_class('rsnapshot::config') }
|
|
||||||
it { is_expected.to contain_class('rsnapshot::install') }
|
|
||||||
end
|
end
|
||||||
|
Loading…
Reference in New Issue
Block a user