summaryrefslogtreecommitdiff
path: root/spec
diff options
context:
space:
mode:
authormo khan <mo@mokhan.ca>2013-04-30 13:15:32 -0600
committermo khan <mo@mokhan.ca>2013-04-30 13:15:32 -0600
commit9b0079caa80b6d3f7a51cc97fe13ab78c38cd02d (patch)
treee02d09e555b6259e53b541b89ea975cd60f4f5b3 /spec
parent9d0e17c02d9d0b1044dcf04cf51c21a94bbd857c (diff)
simple money subtractionHEADmaster
Diffstat (limited to 'spec')
-rw-r--r--spec/unit/money_spec.rb5
1 files changed, 5 insertions, 0 deletions
diff --git a/spec/unit/money_spec.rb b/spec/unit/money_spec.rb
index 9716db2..2934a67 100644
--- a/spec/unit/money_spec.rb
+++ b/spec/unit/money_spec.rb
@@ -21,4 +21,9 @@ describe Money do
result.should == Money.new(2.00)
end
end
+ context "when subtracting money" do
+ it "should return the correct amount" do
+ (Money.new(1.99) - Money.new(0.99)).should == Money.new(1.00)
+ end
+ end
end