Class: ViewComponentCssDsl::Verifier::Finding

Inherits:
Struct
  • Object
show all
Defined in:
lib/view_component_css_dsl/verifier.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Instance Attribute Details

#checkObject

Returns the value of attribute check

Returns:

  • (Object)

    the current value of check



34
35
36
# File 'lib/view_component_css_dsl/verifier.rb', line 34

def check
  @check
end

#componentObject

Returns the value of attribute component

Returns:

  • (Object)

    the current value of component



34
35
36
# File 'lib/view_component_css_dsl/verifier.rb', line 34

def component
  @component
end

#messageObject

Returns the value of attribute message

Returns:

  • (Object)

    the current value of message



34
35
36
# File 'lib/view_component_css_dsl/verifier.rb', line 34

def message
  @message
end

#severityObject

Returns the value of attribute severity

Returns:

  • (Object)

    the current value of severity



34
35
36
# File 'lib/view_component_css_dsl/verifier.rb', line 34

def severity
  @severity
end

Instance Method Details

#error?Boolean

Returns:

  • (Boolean)


41
# File 'lib/view_component_css_dsl/verifier.rb', line 41

def error? = severity == :error

#to_sObject



37
38
39
# File 'lib/view_component_css_dsl/verifier.rb', line 37

def to_s
  "#{component.name || component.inspect} [#{check}] #{severity}: #{message}"
end