flights_gui_tests 2.2.2 → 2.2.3
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
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: bb3236ea6eae5c464cacf87faa5b215638d84db2
|
4
|
+
data.tar.gz: 9d8a8f9561fb033a4fcecd05d796614dd865b113
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 0130ad6be89e443f14ed5ec789a865c7f3e0027d69abb6af2e9bcfb8e868cb3df64be78e49afc783da26f6eea72c3fcc419d66200262db2143b4635efd40e4ec
|
7
|
+
data.tar.gz: d6de8e19aec367a6f998c4fa26edc4d1bb3984b25ff32bb947f710c5ebbd4a4154595f01197a75fb339a963df2180cf64e635cf544c656715905368d8acd0911
|
@@ -35,6 +35,7 @@ Y(/^(?:verifico|valido) los valores del desglose en gracias contra los del check
|
|
35
35
|
@itinerario_checkout.tarifas['total'].should equal(@itinerario_gracias.tarifas['total'])
|
36
36
|
end
|
37
37
|
end
|
38
|
+
@itinerario_gracias.ida.should equal(@itinerario_checkout.ida)
|
38
39
|
end
|
39
40
|
|
40
41
|
Entonces(/^(?:verifico|valido) los datos del vuelo comprado$/) do
|
@@ -24,8 +24,12 @@ class DataCluster
|
|
24
24
|
def ==(other)
|
25
25
|
eq = true
|
26
26
|
self.attributes.each do |attrb|
|
27
|
-
if other
|
28
|
-
|
27
|
+
if other and other.send(attrb)
|
28
|
+
if attrb.to_s!="aerolinea"
|
29
|
+
eq = false if self.send(attrb) != other.send(attrb)
|
30
|
+
else
|
31
|
+
eq = false unless self.send(attrb).include?(other.send(attrb).first)
|
32
|
+
end
|
29
33
|
end
|
30
34
|
end
|
31
35
|
eq
|
@@ -10,19 +10,19 @@ module Thanks
|
|
10
10
|
end
|
11
11
|
|
12
12
|
def roundtrip(html)
|
13
|
-
@idas = cargar_tramos((html/"
|
13
|
+
@idas = cargar_tramos((html/"ul.cluster"))
|
14
14
|
@ida = @idas.first
|
15
|
-
@vueltas = cargar_tramos((html/"
|
16
|
-
@vuelta = @vueltas.
|
15
|
+
@vueltas = cargar_tramos((html/"ul.cluster"))
|
16
|
+
@vuelta = @vueltas.last
|
17
17
|
end
|
18
18
|
|
19
19
|
def oneway(html)
|
20
|
-
@idas = cargar_tramos((html/"
|
20
|
+
@idas = cargar_tramos((html/"ul.cluster"))
|
21
21
|
@ida = @idas.first
|
22
22
|
end
|
23
23
|
|
24
24
|
def multipledestinations(html)
|
25
|
-
data = (html/"
|
25
|
+
data = (html/"ul.cluster")
|
26
26
|
@idas = cargar_tramos(data.first)
|
27
27
|
@ida = @idas.first
|
28
28
|
@vueltas = @idas
|
@@ -31,21 +31,21 @@ module Thanks
|
|
31
31
|
|
32
32
|
def cargar_tramos(lista_tramos)
|
33
33
|
tramos = Array.new
|
34
|
-
(lista_tramos/"
|
34
|
+
(lista_tramos/"li.itinerary").each{ |segmento| tramos << cargar_tramo(segmento)}
|
35
35
|
return tramos
|
36
36
|
end
|
37
37
|
|
38
|
-
def cargar_tramo(
|
39
|
-
aerolineas = (segmento/"li.
|
40
|
-
return DataCluster.new( (
|
41
|
-
(
|
42
|
-
(
|
38
|
+
def cargar_tramo(segmento)
|
39
|
+
aerolineas = (segmento/"li.airline img").collect{|aerolinea| aerolinea.attributes['src'].match(/(..).png/)[1].upcase}
|
40
|
+
return DataCluster.new( (segmento/"span.departure span.city").first.inner_text.strip.no_accents.gsub(/,/,''), #nombre ciudad salida
|
41
|
+
(segmento/"span.arrival span.city").first.inner_text.strip.no_accents.gsub(/,/,''), #nombre ciudad llegada
|
42
|
+
(segmento/"span.date").inner_text.strip, #fecha
|
43
43
|
aerolineas, #aerolineas
|
44
44
|
escala_to_i((segmento/"span.stops-text").inner_text.strip), #escalas
|
45
|
-
(
|
46
|
-
(
|
47
|
-
|
48
|
-
|
45
|
+
(segmento/"span.departure a.airport").first.inner_text.strip.no_accents, #iata ciudad salida
|
46
|
+
(segmento/"span.arrival a.airport").first.inner_text.strip.no_accents, #iata ciudad llegada
|
47
|
+
(segmento/"span.hour").first.inner_text.strip, #horario salida
|
48
|
+
(segmento/"span.hour").last.inner_text.strip, #horario llegada
|
49
49
|
(segmento/"li.duration").inner_text.strip #duracion
|
50
50
|
)
|
51
51
|
end
|
data/features/support/version.rb
CHANGED
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.2.
|
4
|
+
version: 2.2.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- lgonzalez
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-07-
|
11
|
+
date: 2015-07-02 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: henry-container
|