Exception: Spreewald::Steps::FollowTheLink::NoVisitableLinkFound

Inherits:
StandardError
  • Object
show all
Defined in:
lib/steps/follow_the_link.rb

Instance Method Summary collapse

Constructor Details

#initialize(paths, index) ⇒ NoVisitableLinkFound

Returns a new instance of NoVisitableLinkFound.



5
6
7
8
9
10
11
12
13
14
15
# File 'lib/steps/follow_the_link.rb', line 5

def initialize(paths, index)
  error_message = "    Could not follow the \#{index} link in the email.\n  MESSAGE\n  if paths&.empty?\n    error_message << \"Found no link paths in the email.\"\n  else\n    error_message << \"Found these link paths in the email: \#{paths.join(', ')}\"\n  end\n  super(error_message)\nend\n"