fix regexp to match nx at the beginning and at the end of the flags

This commit is contained in:
Edmund Haselwanter 2014-06-05 10:42:23 +02:00
parent 2e7dfc229a
commit 9ae49f3b6b

View file

@ -173,7 +173,7 @@ describe 'System sysctl' do
end
describe 'ExecShield' do
if command('cat /proc/cpuinfo').return_stdout?(/^flags.*?: .*? nx .*?$/)
if command('cat /proc/cpuinfo').return_stdout?(/^flags.*?:.*? nx( .*?)?$/)
context linux_kernel_parameter('kernel.exec-shield') do
its(:value) { should eq 1 }
end