Skip to content

Commit

Permalink
[chef#946] Add missing test
Browse files Browse the repository at this point in the history
chef#959 fixed this, but the regression test was missing

Signed-off-by: David Crosby <dcrosby@fb.com>
  • Loading branch information
dafyddcrosby committed Jun 14, 2024
1 parent 64410f1 commit 2baae9e
Showing 1 changed file with 9 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -112,6 +112,15 @@
RUBY
end

# https://github.com/chef/cookstyle/issues/946
it 'does not register an offense when path is /etc/cron.deny' do
expect_no_offenses(<<~RUBY)
file '/etc/cron.deny' do
action :delete
end
RUBY
end

it 'does not register an offense when the resource name is a variable or method' do
expect_no_offenses(<<~RUBY)
template foo do
Expand Down

0 comments on commit 2baae9e

Please sign in to comment.