eu_central_bank 0.1.5 → 0.2.0

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/CHANGELOG.rdoc CHANGED
@@ -1,6 +1,14 @@
1
1
  = eu_central_bank changelog
2
2
 
3
- == 0.1.4 (Jan 18 2010)
3
+ == 0.2.0 (Feb 19 2011)
4
+
5
+ * Changed to use rounding instead of flooring dues to issues with negative number amounts
6
+
7
+ == 0.1.5 (Jan 18 2011)
8
+
9
+ * Updated the money dependency on the gemspec
10
+
11
+ == 0.1.4 (Jan 18 2011)
4
12
 
5
13
  * Removed the Estonian Kroon from the list of currencies as EU Central Bank does not list it anymore
6
14
 
data/README.rdoc CHANGED
@@ -45,12 +45,8 @@ For performance reasons, you may prefer to read from a file instead. Furthermore
45
45
  # exchange 100 CAD to USD as usual
46
46
  eu_bank.exchange_with(Money.new(100, "CAD"), "USD") # Money.new(80, "USD")
47
47
 
48
- == Deprecation
49
-
50
- Note that the *exchange* method will be deprecated in Money version 3.2.0. eu_central_bank will follow suite and deprecate the method in version 0.2.0
51
-
52
48
  == Note on Patches/Pull Requests
53
-
49
+
54
50
  * Fork the project.
55
51
  * Make your feature addition or bug fix.
56
52
  * Add tests for it. This is important so I don't break it in a
@@ -60,4 +56,4 @@ Note that the *exchange* method will be deprecated in Money version 3.2.0. eu_ce
60
56
 
61
57
  == Copyright
62
58
 
63
- Copyright (c) 2010 Wong Liang Zan. See LICENSE for details.
59
+ Copyright (c) 2010 RubyMoney. See LICENSE for details.
@@ -1,7 +1,7 @@
1
1
  require 'rubygems'
2
2
  require 'open-uri'
3
3
  require 'nokogiri'
4
- gem 'money', '=3.5.4'
4
+ gem 'money', '=3.5.5'
5
5
  require 'money'
6
6
 
7
7
  class InvalidCache < StandardError ; end
@@ -39,7 +39,7 @@ class EuCentralBank < Money::Bank::VariableExchange
39
39
  to_base_rate = get_rate("EUR", to_currency)
40
40
  rate = to_base_rate / from_base_rate
41
41
  end
42
- Money.new((from.cents * rate).floor, to_currency)
42
+ Money.new((from.cents * rate).round, to_currency)
43
43
  end
44
44
 
45
45
  protected
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: eu_central_bank
3
3
  version: !ruby/object:Gem::Version
4
- hash: 17
4
+ hash: 23
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
- - 1
9
- - 5
10
- version: 0.1.5
8
+ - 2
9
+ - 0
10
+ version: 0.2.0
11
11
  platform: ruby
12
12
  authors:
13
13
  - Wong Liang Zan
@@ -16,7 +16,7 @@ autorequire:
16
16
  bindir: bin
17
17
  cert_chain: []
18
18
 
19
- date: 2011-01-18 00:00:00 +08:00
19
+ date: 2011-02-19 00:00:00 +08:00
20
20
  default_executable:
21
21
  dependencies:
22
22
  - !ruby/object:Gem::Dependency
@@ -41,7 +41,7 @@ dependencies:
41
41
  requirement: &id002 !ruby/object:Gem::Requirement
42
42
  none: false
43
43
  requirements:
44
- - - "="
44
+ - - ">="
45
45
  - !ruby/object:Gem::Version
46
46
  hash: 27
47
47
  segments: