global_weather 0.0.1

Sign up to get free protection for your applications and to get access to all the features.
@@ -0,0 +1,17 @@
1
+ require 'test/unit'
2
+ require 'vcr'
3
+ require 'global_weather'
4
+ require 'debugger'
5
+
6
+ VCR.configure do |c|
7
+ c.cassette_library_dir = File.join(File.expand_path(File.dirname(__FILE__)),'vcr','vcr_cassettes')
8
+ c.hook_into :webmock
9
+ c.allow_http_connections_when_no_cassette = true
10
+ end
11
+
12
+
13
+ # all configuration here are passed as options for Savon client
14
+ # see full list http://savonrb.com/version2/globals.html
15
+ GlobalWeather::Client.configure do |config|
16
+ config.log false
17
+ end
@@ -0,0 +1,16 @@
1
+ require_relative File.expand_path(File.dirname(__FILE__) + '/../test_helper')
2
+
3
+ class UtilsTests < Test::Unit::TestCase
4
+
5
+ include GlobalWeather::Utils
6
+
7
+ def test_camelize
8
+ assert_equal 'SkyConditions', camelize('sky_conditions')
9
+ assert_equal 'Temperature', camelize('temperature')
10
+ assert_equal 'RelativeHumidity', camelize('relative_humidity')
11
+ end
12
+
13
+ def test_fix_header
14
+ assert_equal '<tag>Blah</tag>',fix_header!('<?xml some attributes here ?><tag>Blah</tag>')
15
+ end
16
+ end
@@ -0,0 +1,51 @@
1
+ require_relative File.expand_path(File.dirname(__FILE__) + '/../test_helper')
2
+
3
+ class GlobalWeatherTests < Test::Unit::TestCase
4
+ def test_basic_call
5
+ VCR.use_cassette('get_weather_basic_call') do
6
+ weather = GlobalWeather::Weather.new 'Germany', 'Berlin', log: false
7
+
8
+ assert_equal 14,weather.temperature[:C]
9
+ assert_equal 57, weather.temperature[:F]
10
+ assert_equal 10, weather.dew_point[:C]
11
+ assert_equal 50, weather.dew_point[:F]
12
+ assert_equal 29.94, weather.pressure[:Hg]
13
+ assert_equal 1014, weather.pressure[:hPa]
14
+ assert weather.location =~ /Berlin/
15
+ assert weather.location =~ /Germany/
16
+ assert_equal 76, weather.relative_humidity
17
+ assert_equal DateTime.new(2013,8,25,3,20,0), weather.time[:UTC]
18
+ end
19
+ end
20
+
21
+ def test_convert_time_to_datetime
22
+ output = GlobalWeather::Weather.send(:convert_time_to_datetime, 'Aug 21, 2013 - 11:21 AM EDT / 2013.08.21 1521 UTC')
23
+ assert_equal DateTime.new(2013,8,21,15,21,0), output[:UTC]
24
+ assert_equal DateTime.new(2013,8,21,15,21,0), output[:EDT]
25
+ end
26
+
27
+ def test_convert_pressure_to_hash_1
28
+ output = GlobalWeather::Weather.send(:convert_pressure_to_hash, '20.34 in. Hg (688.79 hPa)')
29
+ assert_equal output[:Hg], 20.34
30
+ assert_equal output[:hg], 20.34
31
+ assert_equal output[:hPa], 688.79
32
+ assert_equal output[:hpa], 688.79
33
+ end
34
+
35
+ def test_convert_temperature_to_hash_1
36
+ output = GlobalWeather::Weather.send(:convert_temperature_to_hash, '57 F (14 C)')
37
+ assert_equal output[:F], 57
38
+ assert_equal output[:f], 57
39
+ assert_equal output[:c], 14
40
+ assert_equal output[:C], 14
41
+ end
42
+
43
+ def test_convert_temperature_to_hash_2
44
+ output = GlobalWeather::Weather.send(:convert_temperature_to_hash, ' -31 F (-35 C)')
45
+ assert_equal output[:F], -31
46
+ assert_equal output[:f], -31
47
+ assert_equal output[:c], -35
48
+ assert_equal output[:C], -35
49
+ end
50
+
51
+ end
@@ -0,0 +1,197 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://www.webservicex.net/globalweather.asmx
6
+ body:
7
+ encoding: US-ASCII
8
+ string: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema"
9
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:tns="http://www.webserviceX.NET"
10
+ xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"><env:Body><tns:GetCitiesByCountry><tns:CountryName>Germany</tns:CountryName></tns:GetCitiesByCountry></env:Body></env:Envelope>
11
+ headers:
12
+ Soapaction:
13
+ - ! '"http://www.webserviceX.NET/GetCitiesByCountry"'
14
+ Content-Type:
15
+ - text/xml;charset=UTF-8
16
+ Content-Length:
17
+ - '371'
18
+ Accept:
19
+ - ! '*/*'
20
+ User-Agent:
21
+ - Ruby
22
+ response:
23
+ status:
24
+ code: 200
25
+ message: OK
26
+ headers:
27
+ Cache-Control:
28
+ - private, max-age=0
29
+ Content-Length:
30
+ - '12518'
31
+ Content-Type:
32
+ - text/xml; charset=utf-8
33
+ Server:
34
+ - Microsoft-IIS/7.0
35
+ X-Aspnet-Version:
36
+ - 4.0.30319
37
+ X-Powered-By:
38
+ - ASP.NET
39
+ Date:
40
+ - Sun, 25 Aug 2013 03:53:36 GMT
41
+ body:
42
+ encoding: US-ASCII
43
+ string: ! "<?xml version=\"1.0\" encoding=\"utf-8\"?><soap:Envelope xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\"
44
+ xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\"><soap:Body><GetCitiesByCountryResponse
45
+ xmlns=\"http://www.webserviceX.NET\"><GetCitiesByCountryResult>&lt;NewDataSet&gt;\r\n
46
+ \ &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Berlin-Schoenefeld&lt;/City&gt;\r\n
47
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
48
+ \ &lt;City&gt;Dresden-Klotzsche&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
49
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Erfurt-Bindersleben&lt;/City&gt;\r\n
50
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
51
+ \ &lt;City&gt;Frankfurt / M-Flughafen&lt;/City&gt;\r\n &lt;/Table&gt;\r\n
52
+ \ &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Muenster
53
+ / Osnabrueck&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
54
+ \ &lt;City&gt;Hamburg-Fuhlsbuettel&lt;/City&gt;\r\n &lt;/Table&gt;\r\n
55
+ \ &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Berlin-Tempelhof&lt;/City&gt;\r\n
56
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
57
+ \ &lt;City&gt;Koeln / Bonn&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
58
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Duesseldorf&lt;/City&gt;\r\n
59
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
60
+ \ &lt;City&gt;Munich / Riem&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
61
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Nuernberg&lt;/City&gt;\r\n
62
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
63
+ \ &lt;City&gt;Leipzig-Schkeuditz&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
64
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Saarbruecken
65
+ / Ensheim&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
66
+ \ &lt;City&gt;Stuttgart-Echterdingen&lt;/City&gt;\r\n &lt;/Table&gt;\r\n
67
+ \ &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Berlin-Tegel&lt;/City&gt;\r\n
68
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
69
+ \ &lt;City&gt;Hannover&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
70
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Bremen&lt;/City&gt;\r\n
71
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
72
+ \ &lt;City&gt;Hahn&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
73
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Baden Wurttemberg,
74
+ Neuostheim&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
75
+ \ &lt;City&gt;Hamburg-Finkenwerder&lt;/City&gt;\r\n &lt;/Table&gt;\r\n
76
+ \ &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Luebeck-Blankensee&lt;/City&gt;\r\n
77
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
78
+ \ &lt;City&gt;Monchengladbach&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
79
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Paderborn /
80
+ Lippstadt&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
81
+ \ &lt;City&gt;Dortmund / Wickede&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
82
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Augsburg&lt;/City&gt;\r\n
83
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
84
+ \ &lt;City&gt;Oberpfaffenhofen&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
85
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Friedrichshafen&lt;/City&gt;\r\n
86
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
87
+ \ &lt;City&gt;Mecklenburg-Vorpommern, Parchim&lt;/City&gt;\r\n &lt;/Table&gt;\r\n
88
+ \ &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Bayreuth&lt;/City&gt;\r\n
89
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
90
+ \ &lt;City&gt;Hof&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
91
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Konstanz&lt;/City&gt;\r\n
92
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
93
+ \ &lt;City&gt;Braunschweig&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
94
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Kassel / Calden&lt;/City&gt;\r\n
95
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
96
+ \ &lt;City&gt;Lemwerder&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
97
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Westerland /
98
+ Sylt&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
99
+ \ &lt;City&gt;Essen&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
100
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Spangdahlem&lt;/City&gt;\r\n
101
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
102
+ \ &lt;City&gt;Ramstein&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
103
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Sembach United
104
+ States Air Force&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
105
+ \ &lt;City&gt;Aachen / Merzbruck&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
106
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Ansbach / Katterbach&lt;/City&gt;\r\n
107
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
108
+ \ &lt;City&gt;Bad Kreuznach&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
109
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Giebelstadt&lt;/City&gt;\r\n
110
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
111
+ \ &lt;City&gt;Bergen&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
112
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Gluecksburg
113
+ / Meierwik&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
114
+ \ &lt;City&gt;Idar-Oberstein&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
115
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Kuemmersruck&lt;/City&gt;\r\n
116
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
117
+ \ &lt;City&gt;Wittstock&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
118
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Kalkar&lt;/City&gt;\r\n
119
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
120
+ \ &lt;City&gt;Messstetten&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
121
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Altenstadt&lt;/City&gt;\r\n
122
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
123
+ \ &lt;City&gt;Bueckeburg&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
124
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Celle&lt;/City&gt;\r\n
125
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
126
+ \ &lt;City&gt;Rheine-Bentlage&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
127
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Fritzlar&lt;/City&gt;\r\n
128
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
129
+ \ &lt;City&gt;Itzehoe&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
130
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Laupheim&lt;/City&gt;\r\n
131
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
132
+ \ &lt;City&gt;Mendig&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
133
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Niederstetten&lt;/City&gt;\r\n
134
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
135
+ \ &lt;City&gt;Roth&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
136
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Fassberg&lt;/City&gt;\r\n
137
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
138
+ \ &lt;City&gt;Cottbus Flugplatz&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
139
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Grafenwoehr&lt;/City&gt;\r\n
140
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
141
+ \ &lt;City&gt;Hanau&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
142
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Heidelberg&lt;/City&gt;\r\n
143
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
144
+ \ &lt;City&gt;Hohenfels&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
145
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Illesheim&lt;/City&gt;\r\n
146
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
147
+ \ &lt;City&gt;Kitzingen Usa Af&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
148
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Eggebek&lt;/City&gt;\r\n
149
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
150
+ \ &lt;City&gt;Kiel-Holtenau&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
151
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Nordholz&lt;/City&gt;\r\n
152
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
153
+ \ &lt;City&gt;Diepholz&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
154
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Geilenkirchen&lt;/City&gt;\r\n
155
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
156
+ \ &lt;City&gt;Hohn&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
157
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Jever&lt;/City&gt;\r\n
158
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
159
+ \ &lt;City&gt;Laage&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
160
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Noervenich&lt;/City&gt;\r\n
161
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
162
+ \ &lt;City&gt;Hopsten&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
163
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Preschen&lt;/City&gt;\r\n
164
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
165
+ \ &lt;City&gt;Schleswig-Jagel&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
166
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Wittmundhaven&lt;/City&gt;\r\n
167
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
168
+ \ &lt;City&gt;Trollenhagen&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
169
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Wunstorf&lt;/City&gt;\r\n
170
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
171
+ \ &lt;City&gt;Coleman Mannheim&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
172
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Wiesbaden&lt;/City&gt;\r\n
173
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
174
+ \ &lt;City&gt;Landsberg&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
175
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Buechel&lt;/City&gt;\r\n
176
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
177
+ \ &lt;City&gt;Erding&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
178
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Fuerstenfeldbruck&lt;/City&gt;\r\n
179
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
180
+ \ &lt;City&gt;Holzdorf&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
181
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Ingolstadt&lt;/City&gt;\r\n
182
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
183
+ \ &lt;City&gt;Lechfeld&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
184
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Memmingen&lt;/City&gt;\r\n
185
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
186
+ \ &lt;City&gt;Neuburg / Donau&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
187
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Pferdsfeld&lt;/City&gt;\r\n
188
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
189
+ \ &lt;City&gt;Laarbruch&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
190
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Nordhorn&lt;/City&gt;\r\n
191
+ \ &lt;/Table&gt;\r\n &lt;Table&gt;\r\n &lt;Country&gt;Germany&lt;/Country&gt;\r\n
192
+ \ &lt;City&gt;Guetersloh&lt;/City&gt;\r\n &lt;/Table&gt;\r\n &lt;Table&gt;\r\n
193
+ \ &lt;Country&gt;Germany&lt;/Country&gt;\r\n &lt;City&gt;Brueggen&lt;/City&gt;\r\n
194
+ \ &lt;/Table&gt;\r\n&lt;/NewDataSet&gt;</GetCitiesByCountryResult></GetCitiesByCountryResponse></soap:Body></soap:Envelope>"
195
+ http_version:
196
+ recorded_at: Sun, 25 Aug 2013 03:53:34 GMT
197
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,49 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://www.webservicex.net/globalweather.asmx
6
+ body:
7
+ encoding: US-ASCII
8
+ string: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema"
9
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:tns="http://www.webserviceX.NET"
10
+ xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"><env:Body><tns:GetCitiesByCountry><tns:CountryName>FarFarFarAway</tns:CountryName></tns:GetCitiesByCountry></env:Body></env:Envelope>
11
+ headers:
12
+ Soapaction:
13
+ - ! '"http://www.webserviceX.NET/GetCitiesByCountry"'
14
+ Content-Type:
15
+ - text/xml;charset=UTF-8
16
+ Content-Length:
17
+ - '377'
18
+ Accept:
19
+ - ! '*/*'
20
+ User-Agent:
21
+ - Ruby
22
+ response:
23
+ status:
24
+ code: 200
25
+ message: OK
26
+ headers:
27
+ Cache-Control:
28
+ - private, max-age=0
29
+ Content-Length:
30
+ - '411'
31
+ Content-Type:
32
+ - text/xml; charset=utf-8
33
+ Server:
34
+ - Microsoft-IIS/7.0
35
+ X-Aspnet-Version:
36
+ - 4.0.30319
37
+ X-Powered-By:
38
+ - ASP.NET
39
+ Date:
40
+ - Sun, 25 Aug 2013 03:53:35 GMT
41
+ body:
42
+ encoding: US-ASCII
43
+ string: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
44
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><GetCitiesByCountryResponse
45
+ xmlns="http://www.webserviceX.NET"><GetCitiesByCountryResult>&lt;NewDataSet
46
+ /&gt;</GetCitiesByCountryResult></GetCitiesByCountryResponse></soap:Body></soap:Envelope>
47
+ http_version:
48
+ recorded_at: Sun, 25 Aug 2013 03:53:32 GMT
49
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,56 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://www.webservicex.net/globalweather.asmx
6
+ body:
7
+ encoding: US-ASCII
8
+ string: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema"
9
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:tns="http://www.webserviceX.NET"
10
+ xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"><env:Body><tns:GetWeather><tns:CountryName>Germany</tns:CountryName><tns:CityName>Berlin</tns:CityName></tns:GetWeather></env:Body></env:Envelope>
11
+ headers:
12
+ Soapaction:
13
+ - ! '"http://www.webserviceX.NET/GetWeather"'
14
+ Content-Type:
15
+ - text/xml;charset=UTF-8
16
+ Content-Length:
17
+ - '390'
18
+ Accept:
19
+ - ! '*/*'
20
+ User-Agent:
21
+ - Ruby
22
+ response:
23
+ status:
24
+ code: 200
25
+ message: OK
26
+ headers:
27
+ Cache-Control:
28
+ - private, max-age=0
29
+ Content-Length:
30
+ - '1017'
31
+ Content-Type:
32
+ - text/xml; charset=utf-8
33
+ Server:
34
+ - Microsoft-IIS/7.0
35
+ X-Aspnet-Version:
36
+ - 4.0.30319
37
+ X-Powered-By:
38
+ - ASP.NET
39
+ Date:
40
+ - Sun, 25 Aug 2013 03:53:41 GMT
41
+ body:
42
+ encoding: US-ASCII
43
+ string: ! "<?xml version=\"1.0\" encoding=\"utf-8\"?><soap:Envelope xmlns:soap=\"http://schemas.xmlsoap.org/soap/envelope/\"
44
+ xmlns:xsi=\"http://www.w3.org/2001/XMLSchema-instance\" xmlns:xsd=\"http://www.w3.org/2001/XMLSchema\"><soap:Body><GetWeatherResponse
45
+ xmlns=\"http://www.webserviceX.NET\"><GetWeatherResult>&lt;?xml version=\"1.0\"
46
+ encoding=\"utf-16\"?&gt;\r\n&lt;CurrentWeather&gt;\r\n &lt;Location&gt;Berlin-Tegel,
47
+ Germany (EDDT) 52-34N 013-19E 37M&lt;/Location&gt;\r\n &lt;Time&gt;Aug 24,
48
+ 2013 - 11:20 PM EDT / 2013.08.25 0320 UTC&lt;/Time&gt;\r\n &lt;Wind&gt; from
49
+ the ENE (060 degrees) at 7 MPH (6 KT):0&lt;/Wind&gt;\r\n &lt;Visibility&gt;
50
+ greater than 7 mile(s):0&lt;/Visibility&gt;\r\n &lt;Temperature&gt; 57 F
51
+ (14 C)&lt;/Temperature&gt;\r\n &lt;DewPoint&gt; 50 F (10 C)&lt;/DewPoint&gt;\r\n
52
+ \ &lt;RelativeHumidity&gt; 76%&lt;/RelativeHumidity&gt;\r\n &lt;Pressure&gt;
53
+ 29.94 in. Hg (1014 hPa)&lt;/Pressure&gt;\r\n &lt;Status&gt;Success&lt;/Status&gt;\r\n&lt;/CurrentWeather&gt;</GetWeatherResult></GetWeatherResponse></soap:Body></soap:Envelope>"
54
+ http_version:
55
+ recorded_at: Sun, 25 Aug 2013 03:53:38 GMT
56
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,48 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://www.webservicex.net/globalweather.asmx
6
+ body:
7
+ encoding: US-ASCII
8
+ string: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema"
9
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:tns="http://www.webserviceX.NET"
10
+ xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"><env:Body><tns:GetWeather><tns:CountryName>Blah</tns:CountryName><tns:CityName>Berlin</tns:CityName></tns:GetWeather></env:Body></env:Envelope>
11
+ headers:
12
+ Soapaction:
13
+ - ! '"http://www.webserviceX.NET/GetWeather"'
14
+ Content-Type:
15
+ - text/xml;charset=UTF-8
16
+ Content-Length:
17
+ - '387'
18
+ Accept:
19
+ - ! '*/*'
20
+ User-Agent:
21
+ - Ruby
22
+ response:
23
+ status:
24
+ code: 200
25
+ message: OK
26
+ headers:
27
+ Cache-Control:
28
+ - private, max-age=0
29
+ Content-Length:
30
+ - '373'
31
+ Content-Type:
32
+ - text/xml; charset=utf-8
33
+ Server:
34
+ - Microsoft-IIS/7.0
35
+ X-Aspnet-Version:
36
+ - 4.0.30319
37
+ X-Powered-By:
38
+ - ASP.NET
39
+ Date:
40
+ - Sun, 25 Aug 2013 03:53:38 GMT
41
+ body:
42
+ encoding: US-ASCII
43
+ string: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
44
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><GetWeatherResponse
45
+ xmlns="http://www.webserviceX.NET"><GetWeatherResult>Data Not Found</GetWeatherResult></GetWeatherResponse></soap:Body></soap:Envelope>
46
+ http_version:
47
+ recorded_at: Sun, 25 Aug 2013 03:53:35 GMT
48
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,48 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: post
5
+ uri: http://www.webservicex.net/globalweather.asmx
6
+ body:
7
+ encoding: US-ASCII
8
+ string: <?xml version="1.0" encoding="UTF-8"?><env:Envelope xmlns:xsd="http://www.w3.org/2001/XMLSchema"
9
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:tns="http://www.webserviceX.NET"
10
+ xmlns:env="http://schemas.xmlsoap.org/soap/envelope/"><env:Body><tns:GetWeather><tns:CountryName>Germany</tns:CountryName><tns:CityName>Blah</tns:CityName></tns:GetWeather></env:Body></env:Envelope>
11
+ headers:
12
+ Soapaction:
13
+ - ! '"http://www.webserviceX.NET/GetWeather"'
14
+ Content-Type:
15
+ - text/xml;charset=UTF-8
16
+ Content-Length:
17
+ - '388'
18
+ Accept:
19
+ - ! '*/*'
20
+ User-Agent:
21
+ - Ruby
22
+ response:
23
+ status:
24
+ code: 200
25
+ message: OK
26
+ headers:
27
+ Cache-Control:
28
+ - private, max-age=0
29
+ Content-Length:
30
+ - '373'
31
+ Content-Type:
32
+ - text/xml; charset=utf-8
33
+ Server:
34
+ - Microsoft-IIS/7.0
35
+ X-Aspnet-Version:
36
+ - 4.0.30319
37
+ X-Powered-By:
38
+ - ASP.NET
39
+ Date:
40
+ - Sun, 25 Aug 2013 03:53:39 GMT
41
+ body:
42
+ encoding: US-ASCII
43
+ string: <?xml version="1.0" encoding="utf-8"?><soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/"
44
+ xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema"><soap:Body><GetWeatherResponse
45
+ xmlns="http://www.webserviceX.NET"><GetWeatherResult>Data Not Found</GetWeatherResult></GetWeatherResponse></soap:Body></soap:Envelope>
46
+ http_version:
47
+ recorded_at: Sun, 25 Aug 2013 03:53:36 GMT
48
+ recorded_with: VCR 2.5.0