flights_gui_tests 2.3.21 → 2.3.22
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/checkout/load_steps.rb +1 -1
- data/features/step_definitions/checkout/upselling_steps.rb +2 -1
- data/features/step_definitions/landing/negative_steps.rb +2 -2
- data/features/support/classes/clusters.rb +1 -0
- data/features/support/classes/results/mini_cluster.rb +27 -0
- data/features/support/modules/results/two_oneway.rb +19 -0
- data/features/support/version.rb +1 -1
- data/features/tests/black_list/compras_duplicadas.feature +0 -1
- data/features/tests/checkout/price_jump.feature +1 -1
- data/features/tests/results/matrix/matrix_fare_chart.feature +0 -1
- metadata +3 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: b6cc70dafc68e0f5b01e616c4f8d73257c84f7fd
|
4
|
+
data.tar.gz: c0ea34d1ed423dcb07c016258f56a97c8363eb7e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: b80ce9b2446f52c1a2d5aafb429d0663254921931c0185a06c71410e56e3abd08debb713b40aa11b6604246ecd62abbac491b38df56c47c282e1ff0841db4fc4
|
7
|
+
data.tar.gz: 4ec9534211f5aedaddd67d638d63828995daece99824c2d91dc2f662456d05b14c9dd099c0ade67a4f858aeb92da50009357a755152cfd509404ff78726bd952
|
@@ -20,7 +20,7 @@ Cuando(/^ingreso a un checkout directo para una busqueda '(.*?)' del tipo '(.*?)
|
|
20
20
|
end
|
21
21
|
if AllPages.internacional
|
22
22
|
@page.manage_data.set_header_json({"host"=>"www.us.despegar.com"})
|
23
|
-
@page.ir("www.despegar.com/
|
23
|
+
@page.ir("www.despegar.com/vuelos")
|
24
24
|
$browser.execute_script("javascript:void(document.cookie = 'x-locale=#{AllPages.lang.downcase}-#{AllPages.site.upcase}; domain=despegar.com; Path=/')")
|
25
25
|
end
|
26
26
|
begin
|
@@ -28,7 +28,8 @@ Entonces(/^(?:verifico|valido) que el precio del seguro se muestre correctamente
|
|
28
28
|
@page.precio_seguro_desglose_element.should visible
|
29
29
|
price_detail=@page.precio_seguro_desglose_element.span(:class,'amount').text.gsub(/\.|\,/,'')
|
30
30
|
price_assistance=@page.precio_seguro_element.text.gsub(/\.|\,/,'')
|
31
|
-
|
31
|
+
dias = (@page.manage_data.date_to_1 - @page.manage_data.date_from_1).to_i + 1
|
32
|
+
price_detail.to_i.should be_within(5).of(dias*price_assistance.to_i*(@page.manage_data.adt+@page.manage_data.cnn+@page.manage_data.inf))
|
32
33
|
end
|
33
34
|
|
34
35
|
Cuando(/^muestro el popup de la cobertura completa$/) do
|
@@ -25,7 +25,7 @@ Entonces(/^(?:verifico|valido) que si paso tres ciudades en la url de error$/) d
|
|
25
25
|
end
|
26
26
|
|
27
27
|
Entonces(/^(?:verifico|valido) que fechas iguales no de error$/) do
|
28
|
-
@page.ir(@path_landing[1] + "1/2015-
|
28
|
+
@page.ir(@path_landing[1] + "1/2015-12-05/2015-12-05/" + @path_landing[2] + @path_landing[3])
|
29
29
|
@page.simbolo_error_element.when_visible(timeout=10)
|
30
30
|
@page.mensaje_element.text.no_accents.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")
|
31
31
|
end
|
@@ -43,7 +43,7 @@ Entonces(/^(?:verifico|valido) que paginado negativo de error$/) do
|
|
43
43
|
end
|
44
44
|
|
45
45
|
Entonces(/^(?:verifico|valido) que si la fecha de ida ingresada es posterior a la fecha de vuelta de error$/) do
|
46
|
-
@page.ir(@path_landing[1] + "1/2015-
|
46
|
+
@page.ir(@path_landing[1] + "1/2015-12-05/2015-12-04/" + @path_landing[2] + @path_landing[3])
|
47
47
|
@page.simbolo_error_element.when_visible(timeout=10)
|
48
48
|
@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")
|
49
49
|
end
|
@@ -5,6 +5,7 @@ require_relative 'results/old_cluster'
|
|
5
5
|
require_relative 'results/old_details_cluster'
|
6
6
|
require_relative 'results/new_cluster'
|
7
7
|
require_relative 'results/new_details_cluster'
|
8
|
+
require_relative 'results/mini_cluster'
|
8
9
|
require_relative 'checkout/old_cluster'
|
9
10
|
require_relative 'checkout/new_cluster'
|
10
11
|
require_relative 'checkout/render_cluster'
|
@@ -0,0 +1,27 @@
|
|
1
|
+
module Results
|
2
|
+
class MiniCluster
|
3
|
+
attr_accessor :tramo, :tarifas
|
4
|
+
|
5
|
+
def initialize(html,index)
|
6
|
+
self.cargar_precios((html/"div.fare-container"))
|
7
|
+
@tramo = cargar_tramo(html,segmento)
|
8
|
+
@index = index
|
9
|
+
end
|
10
|
+
|
11
|
+
def cargar_tramo(info_ruta,segmento)
|
12
|
+
aerolineas = (segmento/"li.airlines img").collect{|aerolinea| aerolinea.attributes['src'].match(/(..).png/)[1].upcase}
|
13
|
+
return DataCluster.new( nil, #nombre ciudad salida
|
14
|
+
nil, #nombre ciudad llegada
|
15
|
+
(info_ruta/"span.date").inner_text.strip, #fecha
|
16
|
+
aerolineas, #aerolineas
|
17
|
+
escala_to_i((segmento/"span.stops-text").inner_text.strip), #escalas
|
18
|
+
(info_ruta/"span.airport").first.inner_text.strip.no_accents, #iata ciudad salida
|
19
|
+
(info_ruta/"span.airport").last.inner_text.strip.no_accents, #iata ciudad llegada
|
20
|
+
Time.parse((segmento/"span.hour").first.inner_text.strip), #horario salida
|
21
|
+
Time.parse((segmento/"span.hour").last.inner_text.strip), #horario llegada
|
22
|
+
(segmento/"li.time").inner_text.strip #duracion
|
23
|
+
)
|
24
|
+
end
|
25
|
+
|
26
|
+
end
|
27
|
+
end
|
@@ -7,6 +7,13 @@ module Results
|
|
7
7
|
|
8
8
|
link(:opcion_ida_y_vuelta,:css=>".multipleoneway-options .roundtrip a")
|
9
9
|
link(:opcion_ida_separada,:css=>".multipleoneway-options .oneways a")
|
10
|
+
#ordenamientos
|
11
|
+
link(:ordenamiento_aerolinea,:css=>".airlines .change-order")
|
12
|
+
link(:ordenamiento_ida,:css=>".leave .change-order")
|
13
|
+
link(:ordenamiento_escalas,:css=>".stops .change-order")
|
14
|
+
link(:ordenamiento_vuelta,:css=>".arrive .change-order")
|
15
|
+
link(:ordenamiento_duracion,:css=>".time .change-order")
|
16
|
+
link(:ordenamiento_precio,:css=>".price .change-order")
|
10
17
|
|
11
18
|
div(:carga_fecha_ida_separada,:id=>"update-message")
|
12
19
|
|
@@ -14,6 +21,10 @@ module Results
|
|
14
21
|
elements(:lista_de_fechas_con_precio,:li,:css=>".multipleoneway-dates li.with-price")
|
15
22
|
|
16
23
|
li(:fecha_seleccionada,:css=>".multipleoneway-dates li.current")
|
24
|
+
li(:caja_ida,:css=>".departure-item")
|
25
|
+
li(:caja_vuelta,:css=>".arrival-item")
|
26
|
+
|
27
|
+
div(:clusters,:id=>"clusters")
|
17
28
|
|
18
29
|
def primer_fecha_visible()
|
19
30
|
lista_de_fechas_elements.select{|fecha| fecha_element.present?}.first
|
@@ -26,6 +37,14 @@ module Results
|
|
26
37
|
def fecha_seleccionada()
|
27
38
|
fecha_seleccionada_element
|
28
39
|
end
|
40
|
+
|
41
|
+
def clusters
|
42
|
+
@clusters = []
|
43
|
+
doc=Hpricot.parse(clusters_element.html)
|
44
|
+
(doc/"div.cluster").each_with_index do |cluster,i|
|
45
|
+
@clusters << Results::MiniCluster.new(cluster,i)
|
46
|
+
end
|
47
|
+
end
|
29
48
|
|
30
49
|
end
|
31
50
|
end
|
data/features/support/version.rb
CHANGED
@@ -15,7 +15,6 @@ Característica: checkout.compra_duplicada
|
|
15
15
|
Entonces verifico que la pagina no rompa
|
16
16
|
Y espero que termine de cargar la pagina de checkout
|
17
17
|
Y verifico que ingrese al checkout
|
18
|
-
Entonces si ingreso por keeper, ingreso al checkout con cookie "useNewBookingProvider" al "0"
|
19
18
|
Entonces cargo los pasajeros
|
20
19
|
Y cargo los datos de la tarjeta
|
21
20
|
Y si el site es "AR|MX|PE|BR", cargo los datos de facturacion
|
@@ -27,8 +27,8 @@ Característica: checkout.price_jump
|
|
27
27
|
Entonces verifico el popup de cambio de precio
|
28
28
|
Y elijo otro vuelo por el que cambio de vuelo
|
29
29
|
Cuando espero que termine de cargar la pagina de checkout
|
30
|
-
Entonces si el checkout me pide mas datos de tarjeta, cargo los datos de la tarjeta
|
31
30
|
Entonces si aparece el popup de no disponibilidad, elijo otro itinerario
|
31
|
+
Y cargo los datos de la tarjeta
|
32
32
|
Y elijo mas de una cuota con intereses
|
33
33
|
Y completo el mail de contacto para forzar cambio de precio
|
34
34
|
Y si el site es "AR|MX|PE|BR", cargo los datos de facturacion
|
@@ -10,7 +10,6 @@ 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 el site es "BR|MX", ingreso a resultados con cookie "streaming" al "99"
|
14
13
|
Entonces verifico que traiga resultados
|
15
14
|
Y ingreso a la matriz de tendencia de precios
|
16
15
|
Y verifico el mensaje de aclaracion de precio de matriz de tendencia de precios
|
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.3.
|
4
|
+
version: 2.3.22
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- lgonzalez
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-09-
|
11
|
+
date: 2015-09-10 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: henry-container
|
@@ -287,6 +287,7 @@ files:
|
|
287
287
|
- features/support/classes/landing/cluster.rb
|
288
288
|
- features/support/classes/price.rb
|
289
289
|
- features/support/classes/process_manager.rb
|
290
|
+
- features/support/classes/results/mini_cluster.rb
|
290
291
|
- features/support/classes/results/new_cluster.rb
|
291
292
|
- features/support/classes/results/new_details_cluster.rb
|
292
293
|
- features/support/classes/results/old_cluster.rb
|