lib: Added 2 new tests to BalanceReport.

These tests verify the behavior when we input a very specific period.
The second test is meant to make sure that the new upcoming code in
MultiBalanceReports will not change anything in the behavior of
the module BalanceReport.
This commit is contained in:
Nicholas Niro 2017-07-06 12:50:37 -04:00 committed by Simon Michael
parent a204908be6
commit fe2a1b35da

View File

@ -281,6 +281,20 @@ tests_balanceReport =
],
Mixed [usd0])
,"balanceReport with period on a populated period" ~: do
(defreportopts{period_= PeriodBetween (fromGregorian 2008 1 1) (fromGregorian 2008 1 2)}, samplejournal) `gives`
(
[
("assets:bank:checking","assets:bank:checking",0, mamountp' "$1.00")
,("income:salary","income:salary",0, mamountp' "$-1.00")
],
Mixed [usd0])
,"balanceReport with period on an unpopulated period" ~: do
(defreportopts{period_= PeriodBetween (fromGregorian 2008 1 2) (fromGregorian 2008 1 3)}, samplejournal) `gives`
([],Mixed [nullamt])
{-
,"accounts report with account pattern o" ~: