postfix-formula/test/integration/default/controls/postfix_maps_spec.rb
Felipe Zipitria 2a61498fa4
test(default): add inspec for base and maps
Signed-off-by: Felipe Zipitria <fzipitria@perceptyx.com>
2020-06-07 21:47:18 -03:00

21 lines
592 B
Ruby

# frozen_string_literal: true
control 'Postfix maps' do
title 'maps have been generated properly'
describe command('postmap -q example.com /etc/postfix/transport') do
its('stdout') { should eq "10.1.1.1\n" }
its('exit_status') { should eq 0 }
end
describe command('postmap -q example.com /etc/postfix/tls_policy') do
its('stdout') { should eq "encrypt\n" }
its('exit_status') { should eq 0 }
end
describe command('postmap -q .example.com /etc/postfix/tls_policy') do
its('stdout') { should eq "encrypt\n" }
its('exit_status') { should eq 0 }
end
end