From 898d46265f3d0299507a4f74f39c762d51b00a96 Mon Sep 17 00:00:00 2001 From: Shane Emmons Date: Thu, 4 Feb 2010 09:23:29 -0500 Subject: [PATCH] Fixed BRL so it always has a space between symbol and amount --- lib/money/symbols.rb | 4 ++-- test/money_spec.rb | 6 +++--- 2 files changed, 5 insertions(+), 5 deletions(-) diff --git a/lib/money/symbols.rb b/lib/money/symbols.rb index 92666e909d..a047e2c987 100644 --- a/lib/money/symbols.rb +++ b/lib/money/symbols.rb @@ -13,7 +13,7 @@ "LKR" => "₨", "SEK" => "kr", "GHC" => "¢", - "BRL" => "R$" + "BRL" => "R$ ", # Everything else defaults to $ -} \ No newline at end of file +} diff --git a/test/money_spec.rb b/test/money_spec.rb index 78b7e89553..16603fcf0e 100644 --- a/test/money_spec.rb +++ b/test/money_spec.rb @@ -251,7 +251,7 @@ def to_money one["LKR"].should == "₨1.00" # Brazilian Real - one["BRL"].should == "R$1.00" + one["BRL"].should == "R$ 1.00" # Other one["SEK"].should == "kr1.00" @@ -287,11 +287,11 @@ def to_money end specify "#format(:separator => a separator string) works as documented" do - Money.new(100, "BRL").format(:separator => ",").should == "R$1,00" + Money.new(100, "BRL").format(:separator => ",").should == "R$ 1,00" end specify "#format(:delimiter => a delimiter string) works as documented" do - Money.new(100000, "BRL").format(:delimiter => ".").should == "R$1.000.00" + Money.new(100000, "BRL").format(:delimiter => ".").should == "R$ 1.000.00" Money.us_dollar(200000).format(:delimiter => "").should == "$2000.00" end