Class: Capybara::Poltergeist::JSErrorItem

Inherits:
Object
  • Object
show all
Defined in:
lib/capybara/poltergeist/errors.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, stack) ⇒ JSErrorItem

Returns a new instance of JSErrorItem.



17
18
19
20
# File 'lib/capybara/poltergeist/errors.rb', line 17

def initialize(message, stack)
  @message = message
  @stack   = stack
end

Instance Attribute Details

#messageObject (readonly)

Returns the value of attribute message.



15
16
17
# File 'lib/capybara/poltergeist/errors.rb', line 15

def message
  @message
end

#stackObject (readonly)

Returns the value of attribute stack.



15
16
17
# File 'lib/capybara/poltergeist/errors.rb', line 15

def stack
  @stack
end

Instance Method Details

#to_sObject



22
23
24
# File 'lib/capybara/poltergeist/errors.rb', line 22

def to_s
  [message, stack].join("\n")
end