Class: TestSteps::Handlers::CheckTitle

Inherits:
Base
  • Object
show all
Defined in:
lib/functions/handlers/check_browser_title.rb

Instance Method Summary collapse

Methods inherited from Base

#login_button, #login_check, #login_process, #mem_word_check, #open_url_process, perform, #portal_mem_word, register

Instance Method Details

#perform(step_attributes) ⇒ Object



9
10
11
12
13
14
15
16
17
18
19
20
# File 'lib/functions/handlers/check_browser_title.rb', line 9

def perform(step_attributes)
  text_check = step_attributes[:testvalue]

  sleep 2
  if Browser.b.title.eql?(text_check)
    Report.results.puts("Browser title: #{text_check}")
    return true
  else
    Report.results.puts("Title not found: #{text_check}")
    return false
  end
end