flights_gui_tests 2.1.1 → 2.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/features/step_definitions/checkout/load_steps.rb +1 -1
- data/features/step_definitions/checkout/price_jump_steps.rb +19 -1
- data/features/step_definitions/results/matrix_steps.rb +1 -0
- data/features/step_definitions/results/results_steps.rb +1 -1
- data/features/step_definitions/thanks/load_steps.rb +5 -1
- data/features/step_definitions/thanks/thanks_steps.rb +22 -9
- data/features/support/classes/clusters.rb +1 -0
- data/features/support/classes/thanks/cluster.rb +100 -0
- data/features/support/env.rb +2 -0
- data/features/support/modules/checkout/new_checkout/popup.rb +2 -0
- data/features/support/modules/results/matrix/matrix_fare_chart.rb +1 -1
- data/features/support/modules/results/recommendation.rb +2 -2
- data/features/support/pages/checkout/checkout_page.rb +6 -0
- data/features/support/pages/checkout/checkout_page/new_checkout_page.rb +1 -0
- data/features/support/pages/thanks/thanks_page.rb +1 -30
- data/features/support/pages/thanks/thanks_page/new_thanks_page.rb +40 -0
- data/features/support/pages/thanks/thanks_page/old_thanks_page.rb +40 -0
- data/features/support/version.rb +1 -1
- data/features/tests/checkout/book_ok.feature +2 -2
- data/features/tests/checkout/price_jump.feature +54 -1
- data/features/tests/results/matrix/matrix_airlines.feature +1 -0
- data/features/tests/results/matrix/matrix_fare_chart.feature +1 -0
- data/features/tests/results/matrix/matrix_price.feature +1 -0
- data/features/tests/results/pagination.feature +0 -1
- data/henry-context.yml +31 -0
- metadata +5 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: e3930c4f398ca8f78ac9b07d934f9870a589224f
|
4
|
+
data.tar.gz: 4fb413a6ceabfe1605ef6bf83b8f406a3d27c050
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 1a7b9b355c7e9d200975eb4597452154adc6e813e95653e197a31c0dd6cd90a8940e706184180eb008ae2c206eb43deb189df04543a6909ed90f666efc358cd2
|
7
|
+
data.tar.gz: ba10cd6775ba19f65be4bccd9cf27aa5fed2e13330debedc16149c01f3d5e9230688531e52d29ef5b5eab388fbfc1c02846bb6e27f7260285c74d456d6583a88
|
@@ -57,7 +57,7 @@ Entonces(/^espero que termine el pedido de compra$/) do
|
|
57
57
|
puts "No se mostro el popup de transicion de compra"
|
58
58
|
end
|
59
59
|
@page.popup_transicion_compra_element.when_not_visible(timeout=200)
|
60
|
-
Watir::Wait.until(timeout=200){@page.notificacion_error_cac_element.present? or @page.mensaje_error_ux_element.present? or @page.notificacion_warning_ux_element.present? or @page.checkout_id_cash_element.present? or @page.checkout_id_element.present? or @page.popup_nuevo_vuelo_element.present? or @page.popup_nuevo_precio_element.present? or @page.notificacion_error_element.present? or @page.notificacion_warning_element.present? or @page.notificacion_error_ux_element.present?}
|
60
|
+
Watir::Wait.until(timeout=200){@page.desglose_gracias_element.present? or @page.notificacion_error_cac_element.present? or @page.mensaje_error_ux_element.present? or @page.notificacion_warning_ux_element.present? or @page.checkout_id_cash_element.present? or @page.checkout_id_element.present? or @page.popup_nuevo_vuelo_element.present? or @page.popup_nuevo_precio_element.present? or @page.notificacion_error_element.present? or @page.notificacion_warning_element.present? or @page.notificacion_error_ux_element.present?}
|
61
61
|
end
|
62
62
|
|
63
63
|
Y(/^(?:verifico|valido) si no trae errores$/) do
|
@@ -64,4 +64,22 @@ Entonces(/^elijo otro itinerario$/) do
|
|
64
64
|
@itinerario_checkout = @popup_no_disponibilidad_page.elegir_itinerario(0)
|
65
65
|
step "verifico que ingrese al checkout"
|
66
66
|
step "verifico que la pagina no rompa"
|
67
|
-
end
|
67
|
+
end
|
68
|
+
|
69
|
+
Cuando(/^espero que cargue el nuevo popup de cambio de precio$/) do
|
70
|
+
begin
|
71
|
+
@page.new_popup_price_jump_element.when_visible(timeout=60)
|
72
|
+
rescue Watir::Wait::TimeoutError
|
73
|
+
pending("No se mostro el popup de cambio de precio")
|
74
|
+
end
|
75
|
+
end
|
76
|
+
|
77
|
+
Entonces(/^verifico el nuevo popup de cambio de precio$/) do
|
78
|
+
@page.opcion_si_new_price_jump_element.should visible("boton aceptar cambio de precio")
|
79
|
+
@page.link_new_price_jump_element.should visible("boton ver otros vuelos")
|
80
|
+
doc = Hpricot.parse(@page.new_popup_price_jump_element.html)
|
81
|
+
@itinerario_checkout = @page.datos_itinerario
|
82
|
+
@precio_inicial = Price.new((doc/"p.paragraph span.currency").first.inner_text.strip + " " + (doc/"p.paragraph span.amount").first.inner_text.strip)
|
83
|
+
@itinerario_checkout.tarifas['total'].value.should be_within(2).of(@precio_inicial.value)
|
84
|
+
@precio_final = Price.new((doc/"p.paragraph span.currency").last.inner_text.strip + " " + (doc/"p.paragraph span.amount").last.inner_text.strip)
|
85
|
+
end
|
@@ -120,6 +120,7 @@ Cuando(/^(?:verifico|valido) que filtre por una celda de la matriz$/) do
|
|
120
120
|
@page.manage_data.set_from_date(Date.parse("#{(month_bar).attributes['data-outbound-date']}"))
|
121
121
|
@page.barra_precio_minimo_element.div(:class,'fare-chart-bar-content').click
|
122
122
|
step "espero que termine de cargar la pagina de resultados"
|
123
|
+
step "espero que termine de cargar la pagina de streaming de resultados"
|
123
124
|
step "ingreso a la matriz de tendencia de precios"
|
124
125
|
step "verifico el l&f de la matriz de tendencia de precios"
|
125
126
|
step "verifico que la matriz cumpla con el rango de fechas de la busqueda"
|
@@ -12,7 +12,7 @@ Cuando(/^(?:verifico|valido) que las datos de la pagina sean consistente a la bu
|
|
12
12
|
(html/"span.search-info").inner_text.no_accents.downcase.should match(@page.manage_data.city_from_1.name_lang[AllPages.lang].downcase)
|
13
13
|
(html/"span.search-info").inner_text.no_accents.downcase.should match(@page.manage_data.city_to_1.name_lang[AllPages.lang].downcase)
|
14
14
|
(!(html/"div.ux-search").length.zero?).should be_true
|
15
|
-
(!(html/"div
|
15
|
+
(!(html/"div.flights-alerts").length.zero?).should be_true if @page.tipo_de_busqueda=="roundtrip" and !AllPages.internacional
|
16
16
|
(!(html/"div#inline-filters-VERTICAL_FILTERS-wrapper").length.zero?).should be_true
|
17
17
|
end
|
18
18
|
end
|
@@ -1,6 +1,10 @@
|
|
1
1
|
# encoding: utf-8
|
2
2
|
Cuando(/^espero que termine de cargar la pagina de gracias$/) do
|
3
|
-
@page
|
3
|
+
if @page.new_thanks?
|
4
|
+
@page = Thanks::NewThanksPage.new($browser)
|
5
|
+
else
|
6
|
+
@page = Thanks::OldThanksPage.new($browser)
|
7
|
+
end
|
4
8
|
Watir::Wait.until(timeout=120){@page.checkout_id_element.present? or @page.checkout_id_cash_element.present?}
|
5
9
|
end
|
6
10
|
|
@@ -1,15 +1,28 @@
|
|
1
1
|
# encoding: utf-8
|
2
2
|
Entonces(/^(?:verifico|valido) el link de mi despegar$/) do
|
3
|
-
if
|
4
|
-
|
5
|
-
|
6
|
-
|
7
|
-
|
8
|
-
|
3
|
+
if @page.new_thanks?
|
4
|
+
if AllPages.site=~/BR|PT/
|
5
|
+
@page.link_mi_despegar_element.text.no_accents.downcase.should match("Administre a sua (compra|solicitacao de compra) pela Minha Reserva")
|
6
|
+
@page.link_mi_despegar_element.link(:class,"booking-button eva-button-secondary-medium").should visible
|
7
|
+
elsif AllPages.site=~/CN|US|IN/
|
8
|
+
@page.link_mi_despegar_element.text.no_accents.downcase.should match("if you have any questions, login to my bookings")
|
9
|
+
@page.link_mi_despegar_element.link(:class,"booking-button eva-button-secondary-medium").should visible
|
10
|
+
else
|
11
|
+
@page.link_mi_despegar_element.text.no_accents.downcase.should match("Manage your (purchase|request) from My Booking")
|
12
|
+
@page.link_mi_despegar_element.link(:class,"booking-button eva-button-secondary-medium").should visible
|
13
|
+
end
|
9
14
|
else
|
10
|
-
|
11
|
-
|
12
|
-
|
15
|
+
if AllPages.site=~/BR|PT/
|
16
|
+
@page.link_mi_despegar_element.text.no_accents.downcase.should match("em caso de duvidas, acesse")
|
17
|
+
@page.link_mi_despegar_element.link(:id,"my-despegar-link").should visible
|
18
|
+
elsif AllPages.site=~/CN|US|IN/
|
19
|
+
@page.link_mi_despegar_element.text.no_accents.downcase.should match("if you have any questions, login to my bookings")
|
20
|
+
@page.link_mi_despegar_element.link(:id,"my-despegar-link").should visible
|
21
|
+
else
|
22
|
+
@page.link_mi_despegar_element.text.no_accents.downcase.should match("ante cualquier consulta, ingresa a")
|
23
|
+
@page.link_mi_despegar_element.link(:id,"my-despegar-link").should visible
|
24
|
+
end
|
25
|
+
end
|
13
26
|
end
|
14
27
|
|
15
28
|
Y(/^(?:verifico|valido) los valores del desglose en gracias contra los del checkout/) do
|
@@ -0,0 +1,100 @@
|
|
1
|
+
# -*- encoding : utf-8 -*-
|
2
|
+
module Thanks
|
3
|
+
class Cluster
|
4
|
+
attr_accessor :ida, :vuelta, :tarifas, :idas, :vueltas
|
5
|
+
|
6
|
+
def initialize(itinerario,html,page = 0)
|
7
|
+
@fechas = []
|
8
|
+
self.cargar_precios((html/"div.prices"))
|
9
|
+
eval "#{itinerario.downcase}(html)"
|
10
|
+
end
|
11
|
+
|
12
|
+
def roundtrip(html)
|
13
|
+
tramos = cargar_tramos((html/"div.outbound-route div.segment"))
|
14
|
+
@ida = DataCluster.new(tramos.first['salida']['nombre'], tramos.last['llegada']['nombre'], tramos.first['salida']['fecha'], tramos.collect{|tramo| tramo['aerolinea']}, escala_to_i((html/"div.outbound-route span.stops").inner_text.strip), tramos.first['salida']['iata'], tramos.last['llegada']['iata'], tramos.first['salida']['horario'], tramos.last['llegada']['horario'])
|
15
|
+
tramos = cargar_tramos((html/"div.inbound-route div.segment"))
|
16
|
+
@vuelta = DataCluster.new(tramos.first['salida']['nombre'], tramos.last['llegada']['nombre'], tramos.first['salida']['fecha'], tramos.collect{|tramo| tramo['aerolinea']}, escala_to_i((html/"div.outbound-route span.stops").inner_text.strip), tramos.first['salida']['iata'], tramos.last['llegada']['iata'], tramos.first['salida']['horario'], tramos.last['llegada']['horario'])
|
17
|
+
end
|
18
|
+
|
19
|
+
def oneway(html)
|
20
|
+
tramos = cargar_tramos((html/"div.outbound-route div.segment"))
|
21
|
+
@ida = DataCluster.new(tramos.first['salida']['nombre'], tramos.last['llegada']['nombre'], tramos.first['salida']['fecha'], tramos.collect{|tramo| tramo['aerolinea']}, escala_to_i((html/"div.outbound-route span.stops").inner_text.strip), tramos.first['salida']['iata'], tramos.last['llegada']['iata'], tramos.first['salida']['horario'], tramos.last['llegada']['horario'])
|
22
|
+
end
|
23
|
+
|
24
|
+
def multipledestinations(html)
|
25
|
+
data = (html/"div.outbound-route div.segment")
|
26
|
+
data_final = data.delete(data.last)
|
27
|
+
tramos = cargar_tramos(data)
|
28
|
+
@ida = DataCluster.new(tramos.first['salida']['nombre'], tramos.last['llegada']['nombre'], tramos.first['salida']['fecha'], tramos.collect{|tramo| tramo['aerolinea']}, escala_to_i((html/"div.outbound-route span.stops").inner_text.strip), tramos.first['salida']['iata'], tramos.last['llegada']['iata'], tramos.first['salida']['horario'], tramos.last['llegada']['horario'])
|
29
|
+
tramos = cargar_tramos([data_final])
|
30
|
+
@vuelta = DataCluster.new(tramos.first['salida']['nombre'], tramos.last['llegada']['nombre'], tramos.first['salida']['fecha'], tramos.collect{|tramo| tramo['aerolinea']}, escala_to_i((html/"div.outbound-route span.stops").inner_text.strip), tramos.first['salida']['iata'], tramos.last['llegada']['iata'], tramos.first['salida']['horario'], tramos.last['llegada']['horario'])
|
31
|
+
end
|
32
|
+
|
33
|
+
def cargar_tramos(lista_tramos)
|
34
|
+
tramos = Array.new
|
35
|
+
lista_tramos.each{ |segmento| tramos << cargar_tramo(segmento)}
|
36
|
+
return tramos
|
37
|
+
end
|
38
|
+
|
39
|
+
def cargar_tramo(segmento)
|
40
|
+
tramo = Hash.new
|
41
|
+
tramo['aerolinea'] = (segmento/"li.airline-data img").first.attributes['src'].match(/(..).png/)[1].upcase
|
42
|
+
tramo['salida'] = cargar_vuelo((segmento/"li.flight").first)
|
43
|
+
tramo['llegada'] = cargar_vuelo((segmento/"li.flight").last)
|
44
|
+
return tramo
|
45
|
+
end
|
46
|
+
|
47
|
+
def cargar_vuelo(vuelo)
|
48
|
+
vuelo_tmp = Hash.new
|
49
|
+
vuelo_tmp['iata'] = (vuelo/"a.city-code").inner_text.strip
|
50
|
+
vuelo_tmp['nombre'] = (vuelo/"li.location-name").inner_text.strip.no_accents
|
51
|
+
vuelo_tmp['fecha'] = (vuelo/"li.date").inner_text.strip.no_accents
|
52
|
+
@fechas << vuelo_tmp['fecha']
|
53
|
+
vuelo_tmp['horario'] = (vuelo/"li.time").inner_text.gsub(/hs/,'').strip
|
54
|
+
return vuelo_tmp
|
55
|
+
end
|
56
|
+
|
57
|
+
def cargar_precios(html)
|
58
|
+
@tarifas = Hash.new
|
59
|
+
if (html/".adult-price span.price-currency").first
|
60
|
+
@tarifas['tarifa_adulto'] = Price.new((html/".adult-price span.price-currency").first.inner_text.strip)
|
61
|
+
else
|
62
|
+
@tarifas['tarifa_adulto'] = Price.new((html/"div.adult-price-conversion span#local-currency").first.inner_text.strip)
|
63
|
+
end
|
64
|
+
@tarifas['adt'] = Price.new((html/"li.adult_fare span.price-currency").first.inner_text.strip)
|
65
|
+
@tarifas['cnn'] = (html/"li.child_fare").first ? Price.new((html/"li.child_fare span.price-currency").first.inner_text.strip) : Price.new("$ 0",true)
|
66
|
+
@tarifas['inf'] = (html/"li.infant_fare").first ? Price.new((html/"li.infant_fare span.price-currency").first.inner_text.strip) : Price.new("$ 0",true)
|
67
|
+
@tarifas['tasas'] = (html/"li.taxes").first ? Price.new((html/"li.taxes span.price-currency").first.inner_text.strip) : Price.new("$ 0",true)
|
68
|
+
@tarifas['cargos'] = (html/"li.charges").first ? Price.new((html/"li.charges span.price-currency").first.inner_text.strip) : Price.new("$ 0",true)
|
69
|
+
@tarifas['afip'] = (html/"li.tax_afip").first ? Price.new((html/"li.tax_afip span.price-currency").first.inner_text.strip) : Price.new("$ 0",true)
|
70
|
+
@tarifas['encargos'] = (html/"li.service_taxes").first ? Price.new((html/"li.service_taxes span.price-currency").first.inner_text.strip) : Price.new("$ 0",true)
|
71
|
+
@tarifas['seguros'] = (html/"li.destination_service_insurance").first ? Price.new((html/"li.destination_service_insurance span.price-currency").first.inner_text.strip) : Price.new("$ 0",true)
|
72
|
+
@tarifas['descuento'] = (html/"li.payment_discount").first ? Price.new((html/"li.payment_discount span.price-currency").first.inner_text.strip) : Price.new("$ 0",true)
|
73
|
+
@tarifas['total'] = (html/"span#total-price").first ? Price.new((html/"span#total-price").first.inner_text.strip) : Price.new("$ 0",true)
|
74
|
+
end
|
75
|
+
|
76
|
+
def validar_suma_desgloce(linea = "total|tarifa_adulto|tarifa_adulto_dolar")
|
77
|
+
sumaTarifas = 0
|
78
|
+
@tarifas.each_pair do |key,tarifa|
|
79
|
+
if key !~ /#{linea}/
|
80
|
+
sumaTarifas += tarifa.valor
|
81
|
+
end
|
82
|
+
end
|
83
|
+
return sumaTarifas.to_i
|
84
|
+
end
|
85
|
+
|
86
|
+
def escala_to_i(escala)
|
87
|
+
return 0 if escala.to_s =~ /(solo vuelo directo)|(Sin escalas)|(Sem escalas)|(Soamente v.o directo)|(Vuelo Directo)/i
|
88
|
+
return escala.to_s.gsub(/\D/,'').to_i
|
89
|
+
end
|
90
|
+
|
91
|
+
def fechas
|
92
|
+
@fechas.collect{|fecha| Date.parse_new_result(fecha)}.uniq
|
93
|
+
end
|
94
|
+
|
95
|
+
def fechas_fix
|
96
|
+
@fechas.join(" | ")
|
97
|
+
end
|
98
|
+
|
99
|
+
end
|
100
|
+
end
|
data/features/support/env.rb
CHANGED
@@ -60,6 +60,8 @@ require_relative 'pages/checkout/checkout_page/old_checkout_page'
|
|
60
60
|
require_relative 'pages/checkout/checkout_page/new_checkout_page'
|
61
61
|
require_relative 'pages/checkout/popup_results_page'
|
62
62
|
require_relative 'pages/thanks/thanks_page'
|
63
|
+
require_relative 'pages/thanks/thanks_page/new_thanks_page'
|
64
|
+
require_relative 'pages/thanks/thanks_page/old_thanks_page'
|
63
65
|
require_relative 'pages/landing/search_page'
|
64
66
|
require_relative 'pages/landing/new_landing_page'
|
65
67
|
|
@@ -13,8 +13,10 @@ module NewCheckout
|
|
13
13
|
div(:popup_compra_duplicada,:id=>"popup-duplicated-transaction")
|
14
14
|
div(:opcion_no_compra_duplicada,:css=>"#popup-duplicated-transaction .button-no")
|
15
15
|
div(:opcion_si_compra_duplicada,:css=>"#popup-duplicated-transaction .button-yes")
|
16
|
+
div(:new_popup_price_jump,:id=>"popup-price-difference-template")
|
16
17
|
div(:popup_price_jump,:id=>"popup-price-difference")
|
17
18
|
div(:opcion_si_price_jump,:css=>"#popup-price-difference .button-yes")
|
19
|
+
div(:opcion_si_new_price_jump,:css=>"#popup-price-difference-template .button-yes")
|
18
20
|
div(:cerrar_popup_chat,:css=>"#dtalk-container .ux-header-close")
|
19
21
|
span(:cerrar_popup_cobertura,:css=>".popup-upselling-coverage .popup-close-button")
|
20
22
|
span(:cerrar_popup_cantidad_visitantes,:css=>"#searches-count-alert-popup .popup-close-button")
|
@@ -5,7 +5,7 @@ module Results
|
|
5
5
|
|
6
6
|
include PageObject
|
7
7
|
|
8
|
-
div(:tab_matriz_tendencia_precio,:class=>'flights-tab-
|
8
|
+
div(:tab_matriz_tendencia_precio,:class=>'flights-tab-fareChart')
|
9
9
|
div(:matriz_fare_chart,:id=>'fare-chart')
|
10
10
|
div(:fare_chart_principal,:class=>"fare-chart-main")
|
11
11
|
div(:fare_chart_secundario,:class=>"fare-chart-secondary")
|
@@ -7,8 +7,8 @@ module Results
|
|
7
7
|
|
8
8
|
span(:icono_mail,:css=>".icons .icon")
|
9
9
|
|
10
|
-
radio(:primera_opcion_ida,:id
|
11
|
-
radio(:primera_opcion_vuelta,:id
|
10
|
+
radio(:primera_opcion_ida,:id=>/outbound-0/)
|
11
|
+
radio(:primera_opcion_vuelta,:id=>/inbound-0/)
|
12
12
|
|
13
13
|
div(:popup_vuelos,:class=>"flights-popup")
|
14
14
|
div(:popup_mail,:id=>"popup-email")
|
@@ -16,6 +16,8 @@ module Checkout
|
|
16
16
|
|
17
17
|
divs(:secciones_preguntas_riesgo,:class=>"item section radio-group group")
|
18
18
|
|
19
|
+
div(:desglose_gracias,:class=>"boxes")
|
20
|
+
|
19
21
|
li(:asistencia_gratuita,:class=>"item destination_service_insurance free")
|
20
22
|
|
21
23
|
def cargar_url(tipo,ambiente,cabotaje="nil",params={})
|
@@ -95,5 +97,9 @@ module Checkout
|
|
95
97
|
@provider
|
96
98
|
end
|
97
99
|
|
100
|
+
def new_thanks?
|
101
|
+
desglose_gracias_element.present?
|
102
|
+
end
|
103
|
+
|
98
104
|
end
|
99
105
|
end
|
@@ -29,6 +29,7 @@ module Checkout
|
|
29
29
|
div(:cupon_exito,:id=>"voucher-success")
|
30
30
|
div(:clientes_felices,:id=>"happy-clients")
|
31
31
|
div(:link_price_jump,:css=>"#popup-price-difference .popup-link")
|
32
|
+
div(:link_new_price_jump,:css=>"#popup-price-difference-template .popup-link")
|
32
33
|
div(:mensaje_cancelacion,:id=>"cancellation-advice")
|
33
34
|
div(:mensaje_cancelacion_en_el_dia,:id=>"last-minute-advice")
|
34
35
|
div(:mensaje_error_emision_last_minute,:class=>"ux-common-message ux-common-message-error ")
|
@@ -5,32 +5,6 @@ module Thanks
|
|
5
5
|
include Pages::Tags
|
6
6
|
|
7
7
|
include PageObject
|
8
|
-
|
9
|
-
element(:checkout_id,:em,:class=>"checkout-id")
|
10
|
-
element(:checkout_id_cash,:span,:class=>"checkout-id")
|
11
|
-
|
12
|
-
div(:popup_desglose_gracias,:id=>"popup-booking-details")
|
13
|
-
div(:popup_asistencia_al_viajero,:id=>"insurance-recommendation-popup")
|
14
|
-
div(:overlay_asistencia_al_viajero,:id=>"insurance-recommendation-popup-overlay")
|
15
|
-
div(:cerrar_popup_asistencia_al_viajero,:css=>"#insurance-recommendation-popup .flights-message-close")
|
16
|
-
div(:popup_desglose_detalles_gracias,:class=>"flights-popup popup-detail")
|
17
|
-
div(:link_mi_despegar,:class=>"ux-shared-checkout-thanks-ticket-cont")
|
18
|
-
div(:mensaje_alerta,:class=>"ux-common-message ux-common-message-warning ")
|
19
|
-
div(:datos_deposito,:class=>"thanks-reservation-info")
|
20
|
-
|
21
|
-
elements(:pasos_pago_online,:div,:class=>"thanks-reservation-homebanking-step")
|
22
|
-
elements(:links_mas_detalles_gracias,:link,:css=>"#popup-booking-details .stops .number")
|
23
|
-
|
24
|
-
span(:cerrar_popup_desglose_detalles_gracias,:css=>".popup-detail .popup-close-button")
|
25
|
-
span(:cerrar_popup_desglose_gracias,:css=>"#popup-booking-details .popup-close-button")
|
26
|
-
span(:id_cro_pago_online,:class=>"thanks-reservation-homebanking-ticket-numbers")
|
27
|
-
span(:precio_pago_online,:class=>"thanks-reservation-homebanking-price")
|
28
|
-
span(:valor_desglose_ingresos_brutos,:css=>".local_taxes .price-currency")
|
29
|
-
span(:valor_desglose_total,:css=>".total .price-currency")
|
30
|
-
spans(:pasos_deposito,:class=>"thanks-reservation-info-data")
|
31
|
-
|
32
|
-
link(:imprimir_datos_deposito,:id=>"thanks-reservation-cash-print")
|
33
|
-
link(:ver_desglose_gracias,:class=>"ux-shared-checkout-thanks-more")
|
34
8
|
|
35
9
|
def get_results_search_service(type="TOTALFARE")
|
36
10
|
if $HENRY_PARAMS["streaming"]
|
@@ -45,9 +19,6 @@ module Thanks
|
|
45
19
|
json["result"] = self.manage_data.get_results_search_service_streaming(type).first["arg"]
|
46
20
|
return json
|
47
21
|
end
|
48
|
-
|
49
|
-
def datos_itinerario()
|
50
|
-
return NewCheckout::Cluster.new(tipo_de_busqueda,Hpricot.parse(popup_desglose_gracias_element.html))
|
51
|
-
end
|
22
|
+
|
52
23
|
end
|
53
24
|
end
|
@@ -0,0 +1,40 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
module Thanks
|
3
|
+
class NewThanksPage < ThanksPage
|
4
|
+
|
5
|
+
include Pages::Tags
|
6
|
+
|
7
|
+
include PageObject
|
8
|
+
|
9
|
+
element(:checkout_id,:span,:class=>"number")
|
10
|
+
element(:checkout_id_cash,:span,:class=>"number")
|
11
|
+
|
12
|
+
div(:desglose_gracias,:class=>"boxes")
|
13
|
+
div(:popup_asistencia_al_viajero,:id=>"insurance-recommendation-popup")
|
14
|
+
div(:overlay_asistencia_al_viajero,:id=>"insurance-recommendation-popup-overlay")
|
15
|
+
div(:cerrar_popup_asistencia_al_viajero,:css=>"#insurance-recommendation-popup .flights-message-close")
|
16
|
+
div(:popup_desglose_detalles_gracias,:class=>"flights-popup popup-detail")
|
17
|
+
div(:link_mi_despegar,:id=>"self-service")
|
18
|
+
div(:mensaje_alerta,:class=>"ux-common-message ux-common-message-warning ")
|
19
|
+
div(:datos_deposito,:class=>"thanks-reservation-info")
|
20
|
+
|
21
|
+
elements(:pasos_pago_online,:div,:class=>"thanks-reservation-homebanking-step")
|
22
|
+
elements(:links_mas_detalles_gracias,:link,:css=>"#popup-booking-details .stops .number")
|
23
|
+
|
24
|
+
span(:cerrar_popup_desglose_detalles_gracias,:css=>".popup-detail .popup-close-button")
|
25
|
+
span(:cerrar_popup_desglose_gracias,:css=>"#popup-booking-details .popup-close-button")
|
26
|
+
span(:id_cro_pago_online,:class=>"thanks-reservation-homebanking-ticket-numbers")
|
27
|
+
span(:precio_pago_online,:class=>"thanks-reservation-homebanking-price")
|
28
|
+
span(:valor_desglose_ingresos_brutos,:css=>".local_taxes .price-currency")
|
29
|
+
span(:valor_desglose_total,:css=>".total .price-currency")
|
30
|
+
spans(:pasos_deposito,:class=>"thanks-reservation-info-data")
|
31
|
+
|
32
|
+
link(:imprimir_datos_deposito,:id=>"thanks-reservation-cash-print")
|
33
|
+
link(:ver_desglose_gracias,:class=>"detail-handler")
|
34
|
+
|
35
|
+
def datos_itinerario()
|
36
|
+
return Thanks::Cluster.new(tipo_de_busqueda,Hpricot.parse(desglose_gracias_element.html))
|
37
|
+
end
|
38
|
+
|
39
|
+
end
|
40
|
+
end
|
@@ -0,0 +1,40 @@
|
|
1
|
+
# encoding: utf-8
|
2
|
+
module Thanks
|
3
|
+
class OldThanksPage < ThanksPage
|
4
|
+
|
5
|
+
include Pages::Tags
|
6
|
+
|
7
|
+
include PageObject
|
8
|
+
|
9
|
+
element(:checkout_id,:em,:class=>"checkout-id")
|
10
|
+
element(:checkout_id_cash,:span,:class=>"checkout-id")
|
11
|
+
|
12
|
+
div(:popup_desglose_gracias,:id=>"popup-booking-details")
|
13
|
+
div(:popup_asistencia_al_viajero,:id=>"insurance-recommendation-popup")
|
14
|
+
div(:overlay_asistencia_al_viajero,:id=>"insurance-recommendation-popup-overlay")
|
15
|
+
div(:cerrar_popup_asistencia_al_viajero,:css=>"#insurance-recommendation-popup .flights-message-close")
|
16
|
+
div(:popup_desglose_detalles_gracias,:class=>"flights-popup popup-detail")
|
17
|
+
div(:link_mi_despegar,:class=>"ux-shared-checkout-thanks-ticket-cont")
|
18
|
+
div(:mensaje_alerta,:class=>"ux-common-message ux-common-message-warning ")
|
19
|
+
div(:datos_deposito,:class=>"thanks-reservation-info")
|
20
|
+
|
21
|
+
elements(:pasos_pago_online,:div,:class=>"thanks-reservation-homebanking-step")
|
22
|
+
elements(:links_mas_detalles_gracias,:link,:css=>"#popup-booking-details .stops .number")
|
23
|
+
|
24
|
+
span(:cerrar_popup_desglose_detalles_gracias,:css=>".popup-detail .popup-close-button")
|
25
|
+
span(:cerrar_popup_desglose_gracias,:css=>"#popup-booking-details .popup-close-button")
|
26
|
+
span(:id_cro_pago_online,:class=>"thanks-reservation-homebanking-ticket-numbers")
|
27
|
+
span(:precio_pago_online,:class=>"thanks-reservation-homebanking-price")
|
28
|
+
span(:valor_desglose_ingresos_brutos,:css=>".local_taxes .price-currency")
|
29
|
+
span(:valor_desglose_total,:css=>".total .price-currency")
|
30
|
+
spans(:pasos_deposito,:class=>"thanks-reservation-info-data")
|
31
|
+
|
32
|
+
link(:imprimir_datos_deposito,:id=>"thanks-reservation-cash-print")
|
33
|
+
link(:ver_desglose_gracias,:class=>"ux-shared-checkout-thanks-more")
|
34
|
+
|
35
|
+
def datos_itinerario()
|
36
|
+
return NewCheckout::Cluster.new(tipo_de_busqueda,Hpricot.parse(popup_desglose_gracias_element.html))
|
37
|
+
end
|
38
|
+
|
39
|
+
end
|
40
|
+
end
|
data/features/support/version.rb
CHANGED
@@ -17,7 +17,7 @@ Característica: checkout.book_ok
|
|
17
17
|
Y espero que termine de cargar la pagina de checkout
|
18
18
|
Y verifico que ingrese al checkout
|
19
19
|
Entonces si ingreso por keeper, ingreso al checkout con cookie "useNewBookingProvider" al "0"
|
20
|
-
Entonces si
|
20
|
+
Entonces si existe la opcion de cobertura, elijo "no_chequear" si quiero cobertura
|
21
21
|
Y valido los valores del desglose del checkout
|
22
22
|
Y verifico el pixel de Efrontier
|
23
23
|
Y verifico el pixel de trackeame en checkout
|
@@ -44,7 +44,7 @@ Característica: checkout.book_ok
|
|
44
44
|
Y verifico el tag de datalayer
|
45
45
|
Y verifico el pixel de Efrontier
|
46
46
|
Y verifico el pixel de trackeame en gracias
|
47
|
-
Y verifico los datos de la reserva enviados a fenix
|
47
|
+
#Y verifico los datos de la reserva enviados a fenix
|
48
48
|
Y cancelo la reserva en el proveedor
|
49
49
|
|
50
50
|
@pt
|
@@ -112,4 +112,57 @@ Característica: checkout.price_jump
|
|
112
112
|
@oneway
|
113
113
|
Ejemplos:
|
114
114
|
|pais|tipo|cabotage|
|
115
|
-
|BR |oneway|nil|
|
115
|
+
|BR |oneway|nil|
|
116
|
+
|
117
|
+
@price_jump
|
118
|
+
Esquema del escenario: Se ingresa al checkout para forzar cambio de precio y validar popup y valores mostrados en checkout y gracias.
|
119
|
+
Dado como un usuario de '<pais>'
|
120
|
+
* ingreso una busqueda '<tipo>' del tipo '<cabotage>'
|
121
|
+
Cuando realizo la busqueda
|
122
|
+
Entonces verifico que la pagina no rompa
|
123
|
+
Cuando espero que termine de cargar la pagina de resultados
|
124
|
+
Entonces verifico que traiga resultados
|
125
|
+
Y cierro popups
|
126
|
+
Cuando elijo un itinerario y paso a checkout
|
127
|
+
Entonces verifico que la pagina no rompa
|
128
|
+
Y espero que termine de cargar la pagina de checkout
|
129
|
+
Y verifico que ingrese al checkout
|
130
|
+
Entonces cargo los pasajeros
|
131
|
+
Y cargo los datos de la tarjeta
|
132
|
+
Y elijo mas de una cuota con intereses
|
133
|
+
Y si existe la opcion de cobertura, elijo "no_chequear" si quiero cobertura
|
134
|
+
Y si el site es "AR|MX|PE|BR", cargo los datos de facturacion
|
135
|
+
Y cargo los datos de contacto
|
136
|
+
Y completo el mail de contacto para forzar cambio de precio
|
137
|
+
Cuando acepto y compro
|
138
|
+
Cuando espero que cargue el nuevo popup de cambio de precio
|
139
|
+
Entonces verifico el nuevo popup de cambio de precio
|
140
|
+
Y elijo otro vuelo por el que cambio de vuelo
|
141
|
+
Cuando espero que termine de cargar la pagina de checkout
|
142
|
+
Entonces si el checkout me pide mas datos de tarjeta, cargo los datos de la tarjeta
|
143
|
+
Entonces si aparece el popup de no disponibilidad, elijo otro itinerario
|
144
|
+
Y elijo mas de una cuota con intereses
|
145
|
+
Y completo el mail de contacto para forzar cambio de precio
|
146
|
+
Y si el site es "AR|MX|PE|BR", cargo los datos de facturacion
|
147
|
+
Cuando acepto y compro
|
148
|
+
Cuando espero que cargue el nuevo popup de cambio de precio
|
149
|
+
Entonces verifico el nuevo popup de cambio de precio
|
150
|
+
Y elijo el mismo vuelo que cambio de precio
|
151
|
+
Y espero que cargue las preguntas de riesgo
|
152
|
+
Y si se muestran las preguntas de riesgo, completo las preguntas de riesgo
|
153
|
+
Entonces espero que termine el pedido de compra
|
154
|
+
Y verifico si no trae errores
|
155
|
+
Entonces si aparece el popup de no disponibilidad, elijo un itinerario para checkout de nuevas formas de pago del popup de no disponibilidad
|
156
|
+
Entonces espero que termine de cargar la pagina de gracias
|
157
|
+
Y verifico que ingrese a la pagina de gracias
|
158
|
+
Y verifico el popup de asistencia al viajero
|
159
|
+
Y verifico el link de mi despegar
|
160
|
+
Y verifico los datos del vuelo comprado
|
161
|
+
Y verifico que el nuevo precio final sea el correcto
|
162
|
+
Y verifico el tag de datalayer
|
163
|
+
|
164
|
+
@co
|
165
|
+
@oneway
|
166
|
+
Ejemplos:
|
167
|
+
|pais|tipo|cabotage|
|
168
|
+
|CO |oneway|nil|
|
@@ -10,6 +10,7 @@ Característica: results.matrix_airlines
|
|
10
10
|
Cuando realizo la busqueda
|
11
11
|
Entonces verifico que la pagina no rompa
|
12
12
|
Cuando espero que termine de cargar la pagina de resultados
|
13
|
+
Cuando si pruebo streaming, ingreso a resultados streaming
|
13
14
|
Entonces verifico que traiga resultados
|
14
15
|
Cuando elijo en la matriz una aerolinea a aplicar
|
15
16
|
Entonces filtro por matriz una aerolinea
|
@@ -10,6 +10,7 @@ Característica: results.matrix_fare_chart
|
|
10
10
|
Cuando realizo la busqueda
|
11
11
|
Entonces verifico que la pagina no rompa
|
12
12
|
Cuando espero que termine de cargar la pagina de resultados
|
13
|
+
Cuando si pruebo streaming, ingreso a resultados streaming
|
13
14
|
Entonces verifico que traiga resultados
|
14
15
|
Y ingreso a la matriz de tendencia de precios
|
15
16
|
Y verifico el mensaje de aclaracion de precio de matriz de tendencia de precios
|
@@ -10,6 +10,7 @@ Característica: results.matrix_price
|
|
10
10
|
Cuando realizo la busqueda
|
11
11
|
Entonces verifico que la pagina no rompa
|
12
12
|
Cuando espero que termine de cargar la pagina de resultados
|
13
|
+
Cuando si pruebo streaming, ingreso a resultados streaming
|
13
14
|
Entonces verifico que traiga resultados
|
14
15
|
Y si no se muestra la matriz de precios, realizo las busquedas para recargar la matriz
|
15
16
|
Cuando espero que termine de cargar la pagina de resultados
|
data/henry-context.yml
CHANGED
@@ -12208,6 +12208,37 @@ tasks:
|
|
12208
12208
|
recipients:
|
12209
12209
|
- estebanldh@gmail.com
|
12210
12210
|
- nsimean@despegar.com
|
12211
|
+
- name: checkout.price_jump.co
|
12212
|
+
class_name: Henry::Task::CucumberTask
|
12213
|
+
options:
|
12214
|
+
tags:
|
12215
|
+
- checkout
|
12216
|
+
- price_jump
|
12217
|
+
- co
|
12218
|
+
expand: true
|
12219
|
+
no-source: true
|
12220
|
+
reports:
|
12221
|
+
- format: html
|
12222
|
+
name: ${DATE}_${TASK_NAME}.html
|
12223
|
+
recipients:
|
12224
|
+
- estebanldh@gmail.com
|
12225
|
+
- nsimean@despegar.com
|
12226
|
+
- name: checkout.price_jump.co.oneway
|
12227
|
+
class_name: Henry::Task::CucumberTask
|
12228
|
+
options:
|
12229
|
+
tags:
|
12230
|
+
- checkout
|
12231
|
+
- price_jump
|
12232
|
+
- co
|
12233
|
+
- oneway
|
12234
|
+
expand: true
|
12235
|
+
no-source: true
|
12236
|
+
reports:
|
12237
|
+
- format: html
|
12238
|
+
name: ${DATE}_${TASK_NAME}.html
|
12239
|
+
recipients:
|
12240
|
+
- estebanldh@gmail.com
|
12241
|
+
- nsimean@despegar.com
|
12211
12242
|
- name: checkout.braspag
|
12212
12243
|
class_name: Henry::Task::CucumberTask
|
12213
12244
|
options:
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: flights_gui_tests
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.1.
|
4
|
+
version: 2.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- lgonzalez
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-06-
|
11
|
+
date: 2015-06-29 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: henry-container
|
@@ -293,6 +293,7 @@ files:
|
|
293
293
|
- features/support/classes/results/old_cluster.rb
|
294
294
|
- features/support/classes/results/old_details_cluster.rb
|
295
295
|
- features/support/classes/string.rb
|
296
|
+
- features/support/classes/thanks/cluster.rb
|
296
297
|
- features/support/env.rb
|
297
298
|
- features/support/hooks.rb
|
298
299
|
- features/support/matchers.rb
|
@@ -346,6 +347,8 @@ files:
|
|
346
347
|
- features/support/pages/results/desambiguation_city_page.rb
|
347
348
|
- features/support/pages/results/search_page.rb
|
348
349
|
- features/support/pages/thanks/thanks_page.rb
|
350
|
+
- features/support/pages/thanks/thanks_page/new_thanks_page.rb
|
351
|
+
- features/support/pages/thanks/thanks_page/old_thanks_page.rb
|
349
352
|
- features/support/version.rb
|
350
353
|
- features/tests/black_list/busquedas_promo.feature
|
351
354
|
- features/tests/black_list/cac.feature
|