spbus 0.0.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
Files changed (37) hide show
  1. checksums.yaml +4 -4
  2. data/example.rb +14 -18
  3. data/lib/spbus/bus.rb +2 -3
  4. data/lib/spbus/request.rb +31 -0
  5. data/lib/spbus/route.rb +6 -40
  6. data/lib/spbus/scrapers/locations.rb +48 -0
  7. data/lib/spbus/scrapers/route_details.rb +56 -0
  8. data/lib/spbus/scrapers/routes.rb +74 -0
  9. data/lib/spbus/version.rb +1 -1
  10. data/lib/spbus.rb +23 -5
  11. data/spbus.gemspec +1 -1
  12. data/spec/bus_spec.rb +12 -0
  13. data/spec/cassettes/auth_request.yml +278 -0
  14. data/spec/cassettes/{SpBus_Crawler/_fetch_routes/returns_all_bus_routes.yml → bus_routes.yml} +26269 -26401
  15. data/spec/cassettes/buses_locations.yml +276 -0
  16. data/spec/cassettes/invalid_route_detail.yml +276 -0
  17. data/spec/cassettes/normal_request.yml +136 -0
  18. data/spec/cassettes/normal_route_detail.yml +278 -0
  19. data/spec/cassettes/one_way_route_detail.yml +278 -0
  20. data/spec/request_spec.rb +39 -0
  21. data/spec/route_spec.rb +23 -32
  22. data/spec/scrapers/locations_scraper_spec.rb +24 -0
  23. data/spec/scrapers/route_details_scraper_spec.rb +68 -0
  24. data/spec/scrapers/routes_scraper_spec.rb +30 -0
  25. data/spec/spbus_spec.rb +40 -0
  26. data/spec/spec_helper.rb +1 -1
  27. metadata +35 -25
  28. data/lib/spbus/crawler.rb +0 -52
  29. data/lib/spbus/locations.rb +0 -37
  30. data/spec/cassettes/SpBus_Crawler/_fetch_routes/returns_creates_a_Route_object_for_every_found_route.yml +0 -32809
  31. data/spec/cassettes/SpBus_Locations/_fetch_locations/retrieves_all_buses_locations.yml +0 -34
  32. data/spec/cassettes/SpBus_Route/_fetch_details/sets_destination_attribute.yml +0 -36
  33. data/spec/cassettes/SpBus_Route/_fetch_details/sets_origin_attribute.yml +0 -36
  34. data/spec/cassettes/SpBus_Route/_fetch_details/sets_route_position_codes.yml +0 -36
  35. data/spec/cassettes/SpBus_Route/_to_h/returns_a_hash.yml +0 -36
  36. data/spec/crawler_spec.rb +0 -20
  37. data/spec/locations_spec.rb +0 -18
@@ -0,0 +1,276 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: http://olhovivo.sptrans.com.br/
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers:
10
+ Accept-Encoding:
11
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
12
+ Accept:
13
+ - '*/*'
14
+ User-Agent:
15
+ - Ruby
16
+ response:
17
+ status:
18
+ code: 200
19
+ message: OK
20
+ headers:
21
+ Cache-Control:
22
+ - private
23
+ Content-Type:
24
+ - text/html; charset=utf-8
25
+ Server:
26
+ - Microsoft-IIS/7.5
27
+ X-Frame-Options:
28
+ - DENY
29
+ X-Aspnetmvc-Version:
30
+ - '4.0'
31
+ X-Aspnet-Version:
32
+ - 4.0.30319
33
+ Set-Cookie:
34
+ - apiCredentials-v0=878D287EDFBC6114B23AFB13AD4E3797A4D91C8F59039CDC376494D7176F153F8C66E55BFFD5B2612092C971296F0DEEB14F0FE1048B2A2BA78727D40D7E121BF9F1F4C2D8AC32D17533FF1BB78958C81B1B48F684FAF2920EABA2BB1D78DC0F5C01BAD6C7B60C9E976D11530F735D697DA55CF2C38F61A9DFD4E260D7485F84EA51C8177B164B326A6FE2254F31B355AF8133B5AD4BCD7480413BD019972C53D837CEF14E3FD2F327465C089525AE4F6ED1A5ECAB9C6E05E75B69AF4E19EF377051476164435D552B23FBC8694418AD;
35
+ path=/; HttpOnly
36
+ X-Powered-By:
37
+ - ASP.NET
38
+ Date:
39
+ - Thu, 26 Sep 2013 04:24:13 GMT
40
+ Content-Length:
41
+ - '8223'
42
+ body:
43
+ encoding: ASCII-8BIT
44
+ string: !binary |-
45
+ PCFET0NUWVBFIGh0bWw+DQo8aHRtbCBpZD0iaHRtbFRhZyIgZGlyPSJsdHIi
46
+ IGxh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UaXJhZGVudGVzPC9vcHRpb24+DQo8b3B0aW9uIHZhbHVlPSIz
162
+ Ij5JbmFqYXIgZGUgU291emE8L29wdGlvbj4NCjxvcHRpb24gdmFsdWU9Ijci
163
+ PlBhcmVsaGVpcm9zPC9vcHRpb24+DQo8b3B0aW9uIHZhbHVlPSIxIj5QaXJp
164
+ dHViYTwvb3B0aW9uPg0KPG9wdGlvbiB2YWx1ZT0iMiI+U2FudG8gQW1hcm88
165
+ L29wdGlvbj4NCjxvcHRpb24gdmFsdWU9IjEwIj5QYWVzIGRlIEJhcnJvczwv
166
+ b3B0aW9uPg0KPC9zZWxlY3Q+DQogICAgICAgICAgICAgICAgPHNlbGVjdCBp
167
+ ZD0nc2VsZWN0LWJ0Rm9vdENvbWVudGUnIHRpdGxlPSdDb21lbnRlJyBkYXRh
168
+ LW92ZXJsYXktdGhlbWU9J2QnIGRhdGEtbmF0aXZlLW1lbnU9J2ZhbHNlJz4N
169
+ CiAgICAgICAgICAgICAgICAgICAgPG9wdGlvbj5Db21lbnRlPC9vcHRpb24+
170
+ DQogICAgICAgICAgICAgICAgICAgIDxvcHRpb24gdmFsdWU9JzAnPkVtYWls
171
+ PC9vcHRpb24+DQogICAgICAgICAgICAgICAgICAgIDxvcHRpb24gdmFsdWU9
172
+ JzEnPlR3aXR0ZXI8L29wdGlvbj4NCiAgICAgICAgICAgICAgICA8L3NlbGVj
173
+ dD4NCg0KICAgICAgICAgICAgPC9kaXY+ICAgICAgICAgICAgPGRpdiBpZD0i
174
+ bG9nb3NGb290ZXIiPg0KICAgICAgICAgICAgICAgIDxpbWcgc3JjPSIvQ29u
175
+ dGVudC90aGVtZS9pbWFnZW5zL2xvZ29zRm9vdGVyXzIwMTIwNzE2LmpwZyIg
176
+ YWx0PSJMb2dvbWFyY2EgU1BUcmFucyBlIFByZWZlaXR1cmEgZGEgQ2lkYWRl
177
+ IGRlIFPDo28gUGF1bG8iIC8+DQogICAgICAgICAgICA8L2Rpdj4gICAgICAg
178
+ I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vZHk+DQo8L2h0bWw+
228
+ http_version:
229
+ recorded_at: Thu, 26 Sep 2013 04:24:16 GMT
230
+ - request:
231
+ method: get
232
+ uri: http://olhovivo.sptrans.com.br/v0/Posicao?codigoLinha=32827
233
+ body:
234
+ encoding: US-ASCII
235
+ string: ''
236
+ headers:
237
+ Cookie:
238
+ - apiCredentials-v0=878D287EDFBC6114B23AFB13AD4E3797A4D91C8F59039CDC376494D7176F153F8C66E55BFFD5B2612092C971296F0DEEB14F0FE1048B2A2BA78727D40D7E121BF9F1F4C2D8AC32D17533FF1BB78958C81B1B48F684FAF2920EABA2BB1D78DC0F5C01BAD6C7B60C9E976D11530F735D697DA55CF2C38F61A9DFD4E260D7485F84EA51C8177B164B326A6FE2254F31B355AF8133B5AD4BCD7480413BD019972C53D837CEF14E3FD2F327465C089525AE4F6ED1A5ECAB9C6E05E75B69AF4E19EF377051476164435D552B23FBC8694418AD;
239
+ path=/; HttpOnly
240
+ Accept-Encoding:
241
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
242
+ Accept:
243
+ - '*/*'
244
+ User-Agent:
245
+ - Ruby
246
+ response:
247
+ status:
248
+ code: 200
249
+ message: OK
250
+ headers:
251
+ Cache-Control:
252
+ - no-cache
253
+ Pragma:
254
+ - no-cache
255
+ Content-Type:
256
+ - application/json; charset=utf-8
257
+ Expires:
258
+ - '-1'
259
+ Server:
260
+ - Microsoft-IIS/7.5
261
+ X-Frame-Options:
262
+ - DENY
263
+ X-Aspnet-Version:
264
+ - 4.0.30319
265
+ X-Powered-By:
266
+ - ASP.NET
267
+ Date:
268
+ - Thu, 26 Sep 2013 04:24:14 GMT
269
+ Content-Length:
270
+ - '214'
271
+ body:
272
+ encoding: UTF-8
273
+ string: '{"hr":"01:24","vs":[{"p":"72080","a":true,"py":-23.604221250000002,"px":-46.6749935},{"p":"72432","a":true,"py":-23.647996,"px":-46.748306},{"p":"72337","a":true,"py":-23.653678499999998,"px":-46.759665999999996}]}'
274
+ http_version:
275
+ recorded_at: Thu, 26 Sep 2013 04:24:16 GMT
276
+ recorded_with: VCR 2.5.0
@@ -0,0 +1,276 @@
1
+ ---
2
+ http_interactions:
3
+ - request:
4
+ method: get
5
+ uri: http://olhovivo.sptrans.com.br/
6
+ body:
7
+ encoding: US-ASCII
8
+ string: ''
9
+ headers:
10
+ Accept-Encoding:
11
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
12
+ Accept:
13
+ - '*/*'
14
+ User-Agent:
15
+ - Ruby
16
+ response:
17
+ status:
18
+ code: 200
19
+ message: OK
20
+ headers:
21
+ Cache-Control:
22
+ - private
23
+ Content-Type:
24
+ - text/html; charset=utf-8
25
+ Server:
26
+ - Microsoft-IIS/7.5
27
+ X-Frame-Options:
28
+ - DENY
29
+ X-Aspnetmvc-Version:
30
+ - '4.0'
31
+ X-Aspnet-Version:
32
+ - 4.0.30319
33
+ Set-Cookie:
34
+ - apiCredentials-v0=DA5C648B457E6E7B08ADA49E069C2661240D093CF8EDD12DC58879DF8E4FE38A65318ED025A3F4CF04BEAA7A25A864BDA9F4C8EFA6FF1E0FBDC3BA9813EAB45B76459D41D5397E6080E650C23368A86BADC9A16A474FC93FD05183577D16FADA82527F88BD09454FC2CBE2582335B2D4C77A25F4AB64C3D584E27C07D868182541912A1C57102062E01BD129CB20481CED0A1B7423AC01785F52668DF1700CC6765EF415563457918306E5B60CE5FA5EA67C3EEC8A093B322A2AF2152D7B895F8B282B7167BC5F58E0196E329AB33773;
35
+ path=/; HttpOnly
36
+ X-Powered-By:
37
+ - ASP.NET
38
+ Date:
39
+ - Thu, 26 Sep 2013 04:24:13 GMT
40
+ Content-Length:
41
+ - '8223'
42
+ body:
43
+ encoding: ASCII-8BIT
44
+ string: !binary |-
45
+ PCFET0NUWVBFIGh0bWw+DQo8aHRtbCBpZD0iaHRtbFRhZyIgZGlyPSJsdHIi
46
+ IGxhbmc9InB0LWJyIj4NCjxoZWFkIGlkPSJodG1sV2ViSGVhZGVyIj4NCiAg
47
+ IC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230
+ - request:
231
+ method: get
232
+ uri: http://olhovivo.sptrans.com.br/v0/Linha/Buscar?termosBusca=banana
233
+ body:
234
+ encoding: US-ASCII
235
+ string: ''
236
+ headers:
237
+ Cookie:
238
+ - apiCredentials-v0=DA5C648B457E6E7B08ADA49E069C2661240D093CF8EDD12DC58879DF8E4FE38A65318ED025A3F4CF04BEAA7A25A864BDA9F4C8EFA6FF1E0FBDC3BA9813EAB45B76459D41D5397E6080E650C23368A86BADC9A16A474FC93FD05183577D16FADA82527F88BD09454FC2CBE2582335B2D4C77A25F4AB64C3D584E27C07D868182541912A1C57102062E01BD129CB20481CED0A1B7423AC01785F52668DF1700CC6765EF415563457918306E5B60CE5FA5EA67C3EEC8A093B322A2AF2152D7B895F8B282B7167BC5F58E0196E329AB33773;
239
+ path=/; HttpOnly
240
+ Accept-Encoding:
241
+ - gzip;q=1.0,deflate;q=0.6,identity;q=0.3
242
+ Accept:
243
+ - '*/*'
244
+ User-Agent:
245
+ - Ruby
246
+ response:
247
+ status:
248
+ code: 500
249
+ message: Internal Server Error
250
+ headers:
251
+ Cache-Control:
252
+ - no-cache
253
+ Pragma:
254
+ - no-cache
255
+ Content-Type:
256
+ - application/json; charset=utf-8
257
+ Expires:
258
+ - '-1'
259
+ Server:
260
+ - Microsoft-IIS/7.5
261
+ X-Frame-Options:
262
+ - DENY
263
+ X-Aspnet-Version:
264
+ - 4.0.30319
265
+ X-Powered-By:
266
+ - ASP.NET
267
+ Date:
268
+ - Thu, 26 Sep 2013 04:24:13 GMT
269
+ Content-Length:
270
+ - '36'
271
+ body:
272
+ encoding: UTF-8
273
+ string: '{"Message":"An error has occurred."}'
274
+ http_version:
275
+ recorded_at: Thu, 26 Sep 2013 04:24:16 GMT
276
+ recorded_with: VCR 2.5.0