Skip to content

Commit

Permalink
Jim Weirich found this bug!
Browse files Browse the repository at this point in the history
  • Loading branch information
r00k committed Jun 29, 2012
1 parent 00167db commit ca1b77e
Showing 1 changed file with 10 additions and 0 deletions.
10 changes: 10 additions & 0 deletions spec/data_clump_spec.rb
Expand Up @@ -14,5 +14,15 @@
new(orders, Date.new(2012, 1, 15), Date.new(2012, 1, 30)).
total_sales_within_date_range.should == 5
end

context 'when there are no orders within range' do
it 'returns 0' do
orders = []

OrdersReport.
new(orders, Date.new(2012, 1, 15), Date.new(2012, 1, 30)).
total_sales_within_date_range.should == 0
end
end
end
end

0 comments on commit ca1b77e

Please sign in to comment.