flights_gui_tests 0.8.4 → 0.8.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/features/step_definitions/landing/filters_steps.rb +0 -1
- data/features/step_definitions/landing/negative_steps.rb +15 -19
- data/features/step_definitions/landing/new_landing_steps.rb +4 -4
- data/features/step_definitions/results/filters_steps.rb +1 -4
- data/features/support/pages/landing/search_page.rb +1 -1
- data/features/tests/landing/new_search.feature +10 -0
- data/features/tests/results/new_filters.feature +1 -1
- data/flights_gui_tests.gemspec +1 -1
- metadata +1 -1
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d81023583bc75e85cd6f9564f8ae117e658440ae
|
4
|
+
data.tar.gz: 41f1a87cd441de0ff58266b6bf2f6201e7b33478
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6ca1704c96460fd4c0ad8585e4cd6dc5ca34fa045acc17837538cd57ad95c17cd013bc73f0b38506dc9b598c570242f6aaf3625fad07d90ebff8cc14d11d9bf8
|
7
|
+
data.tar.gz: 1bcb39bcc19306bd5069e809badbd4e17d95b6e9661e99f68e52e5e26b2a91651953b72049ad5999dcc27e0b6d8e5bd071f90c605c856a01e30d37a11b20b9d6
|
@@ -1,5 +1,4 @@
|
|
1
1
|
# encoding: utf-8
|
2
2
|
Entonces(/^(?:verifico|valido) que se muestren los filtros de estadia$/) do
|
3
|
-
@page.execute_script("javascript:void($('.ux-common-filter-toggle').click())") unless @page.browser.div(:class,'ux-common-filter-body').present?
|
4
3
|
@page.filtro_salidas_element.should visible("filtros de salidas")
|
5
4
|
end
|
@@ -4,11 +4,7 @@ Entonces(/^(?:verifico|valido) que el mensaje de error en el cluster sea correct
|
|
4
4
|
clusters=@page.datos_de_itinerarios
|
5
5
|
clusters.each_with_index do |cluster,i|
|
6
6
|
if (cluster.idas.length>1 or (cluster.vueltas and cluster.vueltas.length>1))
|
7
|
-
|
8
|
-
@page.browser.div(:class=>"cluster",:index=>i).links(:class,/buy/)[0].click
|
9
|
-
else
|
10
|
-
@page.browser.div(:class=>"cluster",:index=>i).links(:class,/buy/)[1].click
|
11
|
-
end
|
7
|
+
@page.browser.div(:class=>"cluster",:index=>i).link(:class,"buy btn-buy flights-button").click
|
12
8
|
@page.browser.div(:class=>"cluster",:index=>i).li(:class=>'item error-message',:index=>((cluster.idas.length>1) ? 0 : 1)).text.no_accents.should match("Choose a (return|departure) flight|Por favor, seleccione un vuelo de|Por favor, selecione um voo de")
|
13
9
|
end
|
14
10
|
end
|
@@ -17,38 +13,38 @@ end
|
|
17
13
|
Entonces(/^(?:verifico|valido) que ciudades iguales de error$/) do
|
18
14
|
@path_landing = @page.url.match(/(.+)(vuelos-a|passagens\-aereas\-para)(.+)/)
|
19
15
|
@page.ir(@path_landing[1].gsub(/\/...\/...\//,"/bue/bue/"))
|
20
|
-
@page.
|
21
|
-
|
16
|
+
@page.no_existe_pagina_element.when_visible(timeout=10)
|
17
|
+
#@page.mensaje_element.text.should match("The destination city is the same as the departure city|La ciudad de destino es la misma que la ciudad de origen|A cidade de destino .{1,2} a mesma que a cidade de origem")
|
22
18
|
end
|
23
19
|
|
24
20
|
Entonces(/^(?:verifico|valido) que si paso tres ciudades en la url de error$/) do
|
25
21
|
@page.ir(@path_landing[1] + "#{@page.manage_data.city_to_1.code.downcase}/" + @path_landing[2] + @path_landing[3])
|
26
|
-
@page.
|
27
|
-
|
22
|
+
@page.no_existe_pagina_element.when_visible(timeout=10)
|
23
|
+
#@page.mensaje_element.text.no_accents.should match("La pagina solicitada no es valida|A pagina que voce solicitou nao e valido|The page you requested is not valid")
|
28
24
|
end
|
29
25
|
|
30
26
|
Entonces(/^(?:verifico|valido) que fechas iguales no de error$/) do
|
31
|
-
@page.ir(@path_landing[1] + "1/
|
32
|
-
@page.
|
33
|
-
|
27
|
+
@page.ir(@path_landing[1] + "1/2014-12-05/2014-12-05/" + @path_landing[2] + @path_landing[3])
|
28
|
+
@page.no_existe_pagina_element.when_visible(timeout=10)
|
29
|
+
#@page.mensaje_element.text.should match("No flights were found for your search|No encontramos vuelos para su b.{1,2}squeda|N.{1,2}o foi possivel encontrar assentos disponiveis nos v.{1,2}os buscados")
|
34
30
|
end
|
35
31
|
|
36
32
|
Entonces(/^(?:verifico|valido) que la ciudad "(.*?)" de error$/) do |arg1|
|
37
33
|
@page.ir(@path_landing[1].gsub(/\/...\/...\//,"/bue/xxx/"))
|
38
|
-
@page.
|
39
|
-
|
34
|
+
@page.no_existe_pagina_element.when_visible(timeout=10)
|
35
|
+
#@page.mensaje_element.text.should match("We couldnt understand the city you want to fly|No hemos podido interpretar la ciudad a la que quiere volar|N.{1,2}o encontramos a cidade solicitada")
|
40
36
|
end
|
41
37
|
|
42
38
|
Entonces(/^(?:verifico|valido) que paginado negativo de error$/) do
|
43
39
|
@page.ir(@path_landing[1] + "-1/" + @path_landing[2] + @path_landing[3])
|
44
|
-
@page.
|
45
|
-
|
40
|
+
@page.no_existe_pagina_element.when_visible(timeout=10)
|
41
|
+
#@page.mensaje_element.text.should match("The page you requested is not valid|La pagina solicitada no es valida|A p.{1,2}gina que voc.{1,2} solicitou n.{1,2}o .{1,2} v.{1,2}lido")
|
46
42
|
end
|
47
43
|
|
48
44
|
Entonces(/^(?:verifico|valido) que si la fecha de ida ingresada es posterior a la fecha de vuelta de error$/) do
|
49
|
-
@page.ir(@path_landing[1] + "1/
|
50
|
-
@page.
|
51
|
-
|
45
|
+
@page.ir(@path_landing[1] + "1/2014-12-05/2014-12-04/" + @path_landing[2] + @path_landing[3])
|
46
|
+
@page.no_existe_pagina_element.when_visible(timeout=10)
|
47
|
+
#@page.mensaje_element.text.should match("The departure date entered is later than the return date|La fecha de ida ingresada es posterior a la fecha de vuelta|A data de partida digitada .{1,2} posterior a data de retorno")
|
52
48
|
end
|
53
49
|
|
54
50
|
Entonces(/^(?:verifico|valido) que si la url no tiene el seoPath, se redirige a la pagina que si lo tiene$/) do
|
@@ -27,8 +27,8 @@ Cuando(/^elijo la cantidad de dias de la busqueda$/) do
|
|
27
27
|
end
|
28
28
|
|
29
29
|
Y(/^(?:verifico|valido) los precios mostrados$/) do
|
30
|
-
|
31
|
-
|
30
|
+
@page.precio_banner_element.text.gsub(/ /,'').should equal(@page.precio_fare_chart_element.text.gsub(/ /,''))
|
31
|
+
@page.precio_banner_element.text.gsub(/ /,'').should equal(@page.precio_mensaje_fare_chart_element.text.gsub(/ /,''))
|
32
32
|
end
|
33
33
|
|
34
34
|
Y(/^(?:verifico|valido) que traiga opciones de busquedas$/) do
|
@@ -67,9 +67,9 @@ end
|
|
67
67
|
|
68
68
|
Y(/^(?:verifico|valido) el grafico de fare chart$/) do
|
69
69
|
if @page.tipo_de_busqueda=='oneway'
|
70
|
-
|
70
|
+
@page.mensaje_fare_chart_element.text.no_accents.gsub(/\n/,' ').should match("de vuelos Solo ida desde (.+), saliendo en (.+)")
|
71
71
|
else
|
72
|
-
|
72
|
+
@page.mensaje_fare_chart_element.text.no_accents.gsub(/\n/,' ').should match("de vuelos Ida y vuelta desde (.+), #{@cantidad_dias} dias saliendo en (.+)")
|
73
73
|
end
|
74
74
|
end
|
75
75
|
|
@@ -47,9 +47,7 @@ Cuando(/^limpio el filtro de aerolineas$/) do
|
|
47
47
|
@page.limpiar_filtro_aerolinea_element.set
|
48
48
|
rescue Watir::Exception::ObjectDisabledException
|
49
49
|
@page.cantidad_items_aeropuerto_salida_element.text.to_i.should equal(@total)
|
50
|
-
|
51
|
-
@page.execute_script("javascript:void($('#airlines-all').attr('checked',true))")
|
52
|
-
end
|
50
|
+
end
|
53
51
|
end
|
54
52
|
|
55
53
|
Cuando(/^elijo un aeropuerto (outbound|inbound) a aplicar$/) do |_class|
|
@@ -65,7 +63,6 @@ Cuando(/^elijo un aeropuerto (outbound|inbound) a aplicar$/) do |_class|
|
|
65
63
|
end
|
66
64
|
|
67
65
|
Entonces(/^filtro por aeropuerto$/) do
|
68
|
-
@page.execute_script("javascript:void($('.ux-common-filter-toggle').click())") unless @page.browser.div(:class,'ux-common-filter-body').present?
|
69
66
|
@page.browser.checkbox(:id, (@airport/'input').first.attributes['id']).set
|
70
67
|
end
|
71
68
|
|
@@ -27,6 +27,16 @@ Característica: landing.new_search
|
|
27
27
|
Y verifico que traiga resultados
|
28
28
|
Y verifico que la pagina de resultados sea la correcta
|
29
29
|
|
30
|
+
@ar
|
31
|
+
@roundtrip
|
32
|
+
Ejemplos:
|
33
|
+
|pais|tipo|destino|
|
34
|
+
|AR |roundtrip|NYC|
|
35
|
+
@ar
|
36
|
+
@oneway
|
37
|
+
Ejemplos:
|
38
|
+
|pais|tipo|destino|
|
39
|
+
|AR |oneway|COR|
|
30
40
|
@co
|
31
41
|
@roundtrip
|
32
42
|
Ejemplos:
|
@@ -11,7 +11,7 @@ Característica: results.new_filters
|
|
11
11
|
Entonces verifico que la pagina no rompa
|
12
12
|
Cuando espero que termine de cargar la pagina de resultados
|
13
13
|
Entonces verifico que traiga resultados
|
14
|
-
Cuando fuerzo el abztesting de "filters" al "
|
14
|
+
Cuando fuerzo el abztesting de "filters" al "44"
|
15
15
|
Cuando fuerzo el abztesting de "breakdown" al "88"
|
16
16
|
Y ingreso una busqueda '<tipo>' del tipo '<cabotage>'
|
17
17
|
Y realizo la busqueda
|
data/flights_gui_tests.gemspec
CHANGED
@@ -14,7 +14,7 @@ Gem::Specification.new do |gem|
|
|
14
14
|
|
15
15
|
gem.require_paths = ["lib"] # Usualmente es solo lib -> ["lib"]
|
16
16
|
|
17
|
-
gem.version = '0.8.
|
17
|
+
gem.version = '0.8.5' # La version se debe incrementar cada vez que se desea publicar una nueva version del test.
|
18
18
|
|
19
19
|
gem.add_dependency('henry-container', '>= 0.1.39')
|
20
20
|
gem.add_dependency('page-object')
|