Sha256: 90adff0d7c1467ed2ea153bfdd83c37935f698d39269a6683f95622ead04b002
Contents?: true
Size: 694 Bytes
Versions: 41
Compression:
Stored size: 694 Bytes
Contents
require 'spec_helper' include Serverspec::Helper::RedHat describe cron do it { should have_entry '* * * * * /usr/local/bin/batch.sh' } its(:command) { should eq 'crontab -l | grep -- \\\\\\*\\ \\\\\\*\\ \\\\\\*\\ \\\\\\*\\ \\\\\\*\\ /usr/local/bin/batch.sh' } end describe cron do it { should_not have_entry 'invalid entry' } end describe cron do it { should have_entry('* * * * * /usr/local/bin/batch.sh').with_user('root') } its(:command) { should eq 'crontab -u root -l | grep -- \\\\\\*\\ \\\\\\*\\ \\\\\\*\\ \\\\\\*\\ \\\\\\*\\ /usr/local/bin/batch.sh' } end describe cron do it { should_not have_entry('* * * * * /usr/local/bin/batch.sh').with_user('invalid-user') } end
Version data entries
41 entries across 39 versions & 1 rubygems