Class: Rigor::ConfigAudit::Warning

Inherits:
Data
  • Object
show all
Defined in:
lib/rigor/config_audit.rb

Overview

One config-level finding. ‘kind` discriminates the source key (`:signature_path`, `:library`, `:disabled_rule`, `:severity_override`, `:bundler_bundle_path`, `:bundler_lockfile`, `:rbs_collection_lockfile`); `fields` carries the kind-specific structured data merged into #to_h for JSON consumers.

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#fieldsObject (readonly)

Returns the value of attribute fields

Returns:

  • (Object)

    the current value of fields



32
33
34
# File 'lib/rigor/config_audit.rb', line 32

def fields
  @fields
end

#kindObject (readonly)

Returns the value of attribute kind

Returns:

  • (Object)

    the current value of kind



32
33
34
# File 'lib/rigor/config_audit.rb', line 32

def kind
  @kind
end

#messageObject (readonly)

Returns the value of attribute message

Returns:

  • (Object)

    the current value of message



32
33
34
# File 'lib/rigor/config_audit.rb', line 32

def message
  @message
end

Instance Method Details

#to_hObject



33
34
35
# File 'lib/rigor/config_audit.rb', line 33

def to_h
  { "kind" => kind.to_s, "message" => message }.merge(fields)
end