yahoo_weatherman 0.2 → 0.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.
data/i18n/pt-br.yml CHANGED
@@ -50,5 +50,3 @@
50
50
 
51
51
  locations:
52
52
  Brazil: Brasil
53
- Belo Horizonte: Belzonti
54
- MG: Minas Gerais
@@ -26,7 +26,7 @@ module Weatherman
26
26
  def condition
27
27
  condition = item_attribute 'yweather:condition'
28
28
  condition = do_convertions(condition, [:code, :to_i], [:temp, :to_i], [:date, :to_date], :text)
29
- translate!(condition)
29
+ translate! condition
30
30
  end
31
31
 
32
32
  #
@@ -54,7 +54,7 @@ module Weatherman
54
54
  #
55
55
  def forecasts
56
56
  item_attribute('yweather:forecast').collect do |forecast|
57
- do_convertions(forecast, [:date, :to_date], [:low, :to_i], [:high, :to_i], [:code, :to_i], :day, :text)
57
+ translate! do_convertions(forecast, [:date, :to_date], [:low, :to_i], [:high, :to_i], [:code, :to_i], :day, :text)
58
58
  end
59
59
  end
60
60
 
@@ -68,7 +68,7 @@ module Weatherman
68
68
  #
69
69
  def location
70
70
  location = attribute 'yweather:location'
71
- translate!(location)
71
+ translate! location
72
72
  end
73
73
 
74
74
  # Units:
@@ -96,8 +96,11 @@ DESCRIPTION
96
96
 
97
97
  it 'should translate the location details' do
98
98
  @response.location['country'].should == 'Brasil'
99
- @response.location['region'].should == 'Minas Gerais'
100
- @response.location['city'].should == 'Belzonti'
99
+ end
100
+
101
+ it 'should translate the forecasts details' do
102
+ @response.forecasts.first['text'].should == 'Chuva'
103
+ @response.forecasts.last['text'].should == 'Tempestades Intermitentes'
101
104
  end
102
105
 
103
106
  end
@@ -1,6 +1,6 @@
1
1
  Gem::Specification.new do |gem|
2
2
  gem.name = "yahoo_weatherman"
3
- gem.version = "0.2"
3
+ gem.version = "0.3"
4
4
  gem.authors = ["Dalto Curvelano Junior"]
5
5
  gem.description = "A ruby wrapper to the Yahoo! Weather feed with i18n support."
6
6
  gem.summary = "A ruby wrapper to the Yahoo! Weather feed with i18n support."
metadata CHANGED
@@ -4,8 +4,8 @@ version: !ruby/object:Gem::Version
4
4
  prerelease: false
5
5
  segments:
6
6
  - 0
7
- - 2
8
- version: "0.2"
7
+ - 3
8
+ version: "0.3"
9
9
  platform: ruby
10
10
  authors:
11
11
  - Dalto Curvelano Junior
@@ -13,7 +13,7 @@ autorequire:
13
13
  bindir: bin
14
14
  cert_chain: []
15
15
 
16
- date: 2010-03-15 00:00:00 -03:00
16
+ date: 2010-03-17 00:00:00 -03:00
17
17
  default_executable:
18
18
  dependencies: []
19
19