class RuboCop::Cop::Chef::Sharing::IncludePropertyDescriptions

Resource properties should include description fields to allow automated documentation. Requires Chef Infra Client 13.9 or later.

@example

#### incorrect
property :foo, String

#### correct
property :foo, String, description: "Set the important thing to..."

Constants

MSG
RESTRICT_ON_SEND

Public Instance Methods

on_send(node) click to toggle source
# File lib/rubocop/cop/chef/sharing/include_property_descriptions.rb, line 46
def on_send(node)
  property?(node) do
    add_offense(node, severity: :refactor) unless description_hash?(node)
  end
end