money 5.1.0.beta1 → 5.1.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.
@@ -0,0 +1,13 @@
1
+ module DefaultCurrencyHelper
2
+
3
+ def with_default_currency(iso_code)
4
+ original_default = Money.default_currency
5
+ begin
6
+ Money.default_currency = Money::Currency.new(iso_code)
7
+ yield
8
+ ensure
9
+ Money.default_currency = original_default
10
+ end
11
+ end
12
+
13
+ end
metadata CHANGED
@@ -1,8 +1,8 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: money
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.1.0.beta1
5
- prerelease: 6
4
+ version: 5.1.0
5
+ prerelease:
6
6
  platform: ruby
7
7
  authors:
8
8
  - Tobias Luetke
@@ -13,7 +13,7 @@ authors:
13
13
  autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
- date: 2012-10-01 00:00:00.000000000 Z
16
+ date: 2012-11-10 00:00:00.000000000 Z
17
17
  dependencies:
18
18
  - !ruby/object:Gem::Dependency
19
19
  name: i18n
@@ -86,27 +86,30 @@ executables: []
86
86
  extensions: []
87
87
  extra_rdoc_files: []
88
88
  files:
89
- - config/currency_bc.json
90
89
  - config/currency.json
91
- - lib/money/currency_loader.rb
90
+ - config/currency_bc.json
91
+ - lib/money/bank/base.rb
92
+ - lib/money/bank/variable_exchange.rb
93
+ - lib/money/core_extensions.rb
94
+ - lib/money/currency/heuristics.rb
95
+ - lib/money/currency/loader.rb
96
+ - lib/money/currency.rb
92
97
  - lib/money/money/arithmetic.rb
93
- - lib/money/money/parsing.rb
94
98
  - lib/money/money/formatting.rb
99
+ - lib/money/money/parsing.rb
95
100
  - lib/money/money.rb
96
- - lib/money/core_extensions.rb
97
- - lib/money/currency.rb
98
- - lib/money/bank/variable_exchange.rb
99
- - lib/money/bank/base.rb
100
101
  - lib/money.rb
102
+ - spec/bank/base_spec.rb
103
+ - spec/bank/variable_exchange_spec.rb
104
+ - spec/core_extensions_spec.rb
105
+ - spec/currency/heuristics_spec.rb
101
106
  - spec/currency_spec.rb
102
- - spec/money/parsing_spec.rb
103
- - spec/money/formatting_spec.rb
104
107
  - spec/money/arithmetic_spec.rb
108
+ - spec/money/formatting_spec.rb
109
+ - spec/money/parsing_spec.rb
105
110
  - spec/money_spec.rb
106
- - spec/core_extensions_spec.rb
107
111
  - spec/spec_helper.rb
108
- - spec/bank/variable_exchange_spec.rb
109
- - spec/bank/base_spec.rb
112
+ - spec/support/default_currency_helper.rb
110
113
  - CHANGELOG.md
111
114
  - LICENSE
112
115
  - README.md