Exception: Grntest::ParseError

Inherits:
Error
  • Object
show all
Defined in:
lib/grntest/error.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(type, content, reason) ⇒ ParseError

Returns a new instance of ParseError.



32
33
34
35
36
37
# File 'lib/grntest/error.rb', line 32

def initialize(type, content, reason)
  @type = type
  @content = content
  @reason = reason
  super("failed to parse <#{@type}> content: #{reason}: <#{content}>")
end

Instance Attribute Details

#contentObject (readonly)

Returns the value of attribute content.



31
32
33
# File 'lib/grntest/error.rb', line 31

def content
  @content
end

#reasonObject (readonly)

Returns the value of attribute reason.



31
32
33
# File 'lib/grntest/error.rb', line 31

def reason
  @reason
end

#typeObject (readonly)

Returns the value of attribute type.



31
32
33
# File 'lib/grntest/error.rb', line 31

def type
  @type
end