Skip to main content

ClassEvalActionClass

The department is: ClassEvalActionClass

The full name of the cop is: Chef/Modernize/ClassEvalActionClass

Enabled by defaultSupports autocorrectionTarget Chef Version
EnabledYes12.9+

In Chef Infra Client 12.9 and later it is no longer necessary to call the class_eval method on the action class block.

Examples

incorrect

action_class.class_eval do
  foo
end

correct

action_class do
  foo
end

Configurable attributes

NameDefault valueConfigurable values
Version Added7.23.0String
Include
  • **/resources/*.rb
Array

Was this page helpful?

×









Search Results