Sha256: 795def504a340379627fa991d16f506ffda43318125c31af5e9aabcb53192750

Contents?: true

Size: 690 Bytes

Versions: 26

Compression:

Stored size: 690 Bytes

Contents

require 'spec_helper'

include SpecInfra::Helper::AIX

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

26 entries across 26 versions & 1 rubygems

Version Path
serverspec-1.4.0 spec/aix/cron_spec.rb
serverspec-1.3.0 spec/aix/cron_spec.rb
serverspec-1.2.0 spec/aix/cron_spec.rb
serverspec-1.1.0 spec/aix/cron_spec.rb
serverspec-1.0.0 spec/aix/cron_spec.rb
serverspec-0.16.0 spec/aix/cron_spec.rb
serverspec-0.15.5 spec/aix/cron_spec.rb
serverspec-0.15.4 spec/aix/cron_spec.rb
serverspec-0.15.3 spec/aix/cron_spec.rb
serverspec-0.15.2 spec/aix/cron_spec.rb
serverspec-0.15.1 spec/aix/cron_spec.rb
serverspec-0.15.0 spec/aix/cron_spec.rb
serverspec-0.14.4 spec/aix/cron_spec.rb
serverspec-0.14.3 spec/aix/cron_spec.rb
serverspec-0.14.2 spec/aix/cron_spec.rb
serverspec-0.14.1 spec/aix/cron_spec.rb
serverspec-0.14.0 spec/aix/cron_spec.rb
serverspec-0.13.7 spec/aix/cron_spec.rb
serverspec-0.13.6 spec/aix/cron_spec.rb
serverspec-0.13.5 spec/aix/cron_spec.rb