Module: Avmtrf1::Esosti::Session::Atividades

Defined in:
lib/avmtrf1/esosti/session/atividades.rb

Instance Method Summary collapse

Instance Method Details

#go_to_activitiesObject

rubocop:disable Metrics/AbcSize,Metrics/MethodLength


7
8
9
10
11
12
13
14
15
16
17
18
19
# File 'lib/avmtrf1/esosti/session/atividades.rb', line 7

def go_to_activities # rubocop:disable Metrics/AbcSize,Metrics/MethodLength
  session.wait_for_click(id: 'titlebar-tb_gotoButton')
  el = session.find_element(
    xpath: "//*[@id = 'menuholder']//*[contains(text(), 'Central de Serv')]"
  )
  session.action.move_to(el).perform
  el = session.find_element(
    xpath: "//*[@id = 'menuholder']//*[contains(text(), 'Atividades')]"
  )
  session.action.move_to(el).perform
  el.click
  session.wait_for_element(id: 'SystemNavAppContent-chld')
end

#refresh_activitiesObject


21
22
23
# File 'lib/avmtrf1/esosti/session/atividades.rb', line 21

def refresh_activities
  session.wait_for_click(xpath: "//img[contains(@title, 'Recarregar para atualizar')]")
end

#route_activity_and_backObject


25
26
27
28
29
30
31
# File 'lib/avmtrf1/esosti/session/atividades.rb', line 25

def route_activity_and_back
  session.wait_for_click(
    xpath: "//a[@id = 'ROUTEWF__-tbb_anchor' and contains(@class, 'on')]"
  )
  session.wait_for_click(xpath: "//table[@id = 'completewf-mesh']//button[text() = 'OK']")
  session.wait_for_click(xpath: "//*[text() = 'Visualizar Lista']")
end