Hello all,
I am trying to test the file content from a template using rspec:
require 'spec_helper'
describe 'my_class' do
context 'validate template' do
let :params do
{
:my_puppet_variable => 'test'
}
it do
is_expected.to contain_file('/etc/sysconfig/test').with_content(:my_puppet_variable) })
end
end
end
I tried wrapping the module variable using #{} to interpolate it , with no joy...
Any help would be much appreciated.
Regards
↧