File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -33,19 +33,23 @@ class foo {
33
33
34
34
exec { 'bar':
35
35
command => "echo ${foo} ${bar}",
36
+ onlyif => "${baz}",
37
+ unless => "${bazz}",
36
38
}
37
39
38
40
}
39
41
PUPPET
40
42
end
41
43
42
44
it 'detects multiple unsafe exec command arguments' do
43
- expect ( problems ) . to have ( 2 ) . problems
45
+ expect ( problems ) . to have ( 4 ) . problems
44
46
end
45
47
46
48
it 'creates two warnings' do
47
49
expect ( problems ) . to contain_warning ( msg )
48
50
expect ( problems ) . to contain_warning ( "unsafe interpolation of variable 'bar' in exec command" )
51
+ expect ( problems ) . to contain_warning ( "unsafe interpolation of variable 'baz' in exec command" )
52
+ expect ( problems ) . to contain_warning ( "unsafe interpolation of variable 'bazz' in exec command" )
49
53
end
50
54
end
51
55
You can’t perform that action at this time.
0 commit comments