bd_money 0.0.7 → 0.0.8
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/VERSION +1 -1
- data/bd_money.gemspec +1 -1
- data/lib/bd_money/bd_money.rb +1 -1
- data/spec/bd_money_spec.rb +2 -0
- metadata +3 -3
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.8
|
data/bd_money.gemspec
CHANGED
data/lib/bd_money/bd_money.rb
CHANGED
@@ -20,7 +20,7 @@ class Money
|
|
20
20
|
} unless const_defined?(:FORMATS)
|
21
21
|
|
22
22
|
REMOVE_RE = %r{[$,_ ]} unless const_defined?(:REMOVE_RE)
|
23
|
-
VALID_RE = %r{^(-)?(\d)+(\.\d{1,
|
23
|
+
VALID_RE = %r{^(-)?(\d)+(\.\d{1,30}(e-\d{1,10})?)?$} unless const_defined?(:VALID_RE)
|
24
24
|
|
25
25
|
YAML_TYPE_CLASS = 'npadv.com,2012-03-12' unless const_defined?(:YAML_TYPE_CLASS)
|
26
26
|
YAML_TYPE_MODE = 'money' unless const_defined?(:YAML_TYPE_MODE)
|
data/spec/bd_money_spec.rb
CHANGED
@@ -65,6 +65,8 @@ describe Money do
|
|
65
65
|
it { Money.valid?('.01').should_not be_true }
|
66
66
|
it { Money.valid?('-0.01').should be_true }
|
67
67
|
it { Money.valid?('-.01').should_not be_true }
|
68
|
+
it { Money.valid?('1.0e-05').should be_true }
|
69
|
+
it { Money.valid?('-1.0e-05').should be_true }
|
68
70
|
end
|
69
71
|
|
70
72
|
describe "initialize" do
|
metadata
CHANGED
@@ -1,13 +1,13 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: bd_money
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
hash:
|
4
|
+
hash: 15
|
5
5
|
prerelease:
|
6
6
|
segments:
|
7
7
|
- 0
|
8
8
|
- 0
|
9
|
-
-
|
10
|
-
version: 0.0.
|
9
|
+
- 8
|
10
|
+
version: 0.0.8
|
11
11
|
platform: ruby
|
12
12
|
authors:
|
13
13
|
- Adrian Madrid
|