diff options
-rw-r--r-- | test/doc/transaction-codes-1.test | 22 | ||||
-rw-r--r-- | test/doc/transaction-codes-2.test | 24 | ||||
-rw-r--r-- | test/doc/transaction-notes-1.test | 24 | ||||
-rw-r--r-- | test/doc/transaction-notes-2.test | 23 | ||||
-rw-r--r-- | test/doc/transaction-notes-3.test | 23 | ||||
-rw-r--r-- | test/doc/transaction-notes-4.test | 27 | ||||
-rw-r--r-- | test/doc/transaction-status-1.test | 19 | ||||
-rw-r--r-- | test/doc/transaction-status-2.test | 17 | ||||
-rw-r--r-- | test/doc/transaction-status-3.test | 18 | ||||
-rw-r--r-- | test/doc/transaction-status-4.test | 17 | ||||
-rw-r--r-- | tools/Makefile.am | 12 |
11 files changed, 225 insertions, 1 deletions
diff --git a/test/doc/transaction-codes-1.test b/test/doc/transaction-codes-1.test new file mode 100644 index 00000000..878c5cac --- /dev/null +++ b/test/doc/transaction-codes-1.test @@ -0,0 +1,22 @@ +reg --columns=60 food and code xfer +<<< +2009/10/29 (XFER) Panera Bread + Expenses:Food $4.50 + Assets:Checking + +2009/10/30 (DEP) Pay day! + Assets:Checking $20.00 + Income + +2009/10/30 (XFER) Panera Bread + Expenses:Food $4.50 + Assets:Checking + +2009/10/31 (559385768438A8D7) Panera Bread + Expenses:Food $4.50 + Liabilities:Credit Card +>>>1 +09-Oct-29 Panera Bread Expenses:Food $4.50 $4.50 +09-Oct-30 Panera Bread Expenses:Food $4.50 $9.00 +>>>2 +=== 0 diff --git a/test/doc/transaction-codes-2.test b/test/doc/transaction-codes-2.test new file mode 100644 index 00000000..4e4c76cf --- /dev/null +++ b/test/doc/transaction-codes-2.test @@ -0,0 +1,24 @@ +bal checking --set-reported-account=code +<<< +2009/10/29 (XFER) Panera Bread + Expenses:Food $4.50 + Assets:Checking + +2009/10/30 (DEP) Pay day! + Assets:Checking $20.00 + Income + +2009/10/30 (XFER) Panera Bread + Expenses:Food $4.50 + Assets:Checking + +2009/10/31 (559385768438A8D7) Panera Bread + Expenses:Food $4.50 + Liabilities:Credit Card +>>>1 + $20.00 DEP + $-9.00 XFER +-------------------- + $11.00 +>>>2 +=== 0 diff --git a/test/doc/transaction-notes-1.test b/test/doc/transaction-notes-1.test new file mode 100644 index 00000000..d3fab3b6 --- /dev/null +++ b/test/doc/transaction-notes-1.test @@ -0,0 +1,24 @@ +reg --columns=60 food and note eat +<<< +2009/11/01 Panera Bread ; Got something to eat + Expenses:Food $4.50 + Assets:Checking + +2009/11/01 Panera Bread + ; Type: Coffee + ; Let’s see, I ate a whole bunch of stuff, drank some coffee, + ; pondered a bagel, then decided against the donut. + Expenses:Food $4.50 + Assets:Checking + +2009/11/01 Panera Bread + ; Type: Dining + ; :Eating: + ; This is another long note, after the metadata. + Expenses:Food $4.50 + Assets:Checking +>>>1 +09-Nov-01 Panera Bread Expenses:Food $4.50 $4.50 +09-Nov-01 Panera Bread Expenses:Food $4.50 $9.00 +>>>2 +=== 0 diff --git a/test/doc/transaction-notes-2.test b/test/doc/transaction-notes-2.test new file mode 100644 index 00000000..b7a258e0 --- /dev/null +++ b/test/doc/transaction-notes-2.test @@ -0,0 +1,23 @@ +reg --columns=60 food and tag eating +<<< +2009/11/01 Panera Bread ; Got something to eat + Expenses:Food $4.50 + Assets:Checking + +2009/11/01 Panera Bread + ; Type: Coffee + ; Let’s see, I ate a whole bunch of stuff, drank some coffee, + ; pondered a bagel, then decided against the donut. + Expenses:Food $4.50 + Assets:Checking + +2009/11/01 Panera Bread + ; Type: Dining + ; :Eating: + ; This is another long note, after the metadata. + Expenses:Food $4.50 + Assets:Checking +>>>1 +09-Nov-01 Panera Bread Expenses:Food $4.50 $4.50 +>>>2 +=== 0 diff --git a/test/doc/transaction-notes-3.test b/test/doc/transaction-notes-3.test new file mode 100644 index 00000000..9d532d5f --- /dev/null +++ b/test/doc/transaction-notes-3.test @@ -0,0 +1,23 @@ +reg --columns=60 food and tag type=dining +<<< +2009/11/01 Panera Bread ; Got something to eat + Expenses:Food $4.50 + Assets:Checking + +2009/11/01 Panera Bread + ; Type: Coffee + ; Let’s see, I ate a whole bunch of stuff, drank some coffee, + ; pondered a bagel, then decided against the donut. + Expenses:Food $4.50 + Assets:Checking + +2009/11/01 Panera Bread + ; Type: Dining + ; :Eating: + ; This is another long note, after the metadata. + Expenses:Food $4.50 + Assets:Checking +>>>1 +09-Nov-01 Panera Bread Expenses:Food $4.50 $4.50 +>>>2 +=== 0 diff --git a/test/doc/transaction-notes-4.test b/test/doc/transaction-notes-4.test new file mode 100644 index 00000000..516094c7 --- /dev/null +++ b/test/doc/transaction-notes-4.test @@ -0,0 +1,27 @@ +bal food and tag type --set-reported-account='"Tags:" + tag("Type")' +<<< +2009/11/01 Panera Bread ; Got something to eat + Expenses:Food $4.50 + Assets:Checking + +2009/11/01 Panera Bread + ; Type: Coffee + ; Let’s see, I ate a whole bunch of stuff, drank some coffee, + ; pondered a bagel, then decided against the donut. + Expenses:Food $4.50 + Assets:Checking + +2009/11/01 Panera Bread + ; Type: Dining + ; :Eating: + ; This is another long note, after the metadata. + Expenses:Food $4.50 + Assets:Checking +>>>1 + $9.00 Tags + $4.50 Coffee + $4.50 Dining +-------------------- + $9.00 +>>>2 +=== 0 diff --git a/test/doc/transaction-status-1.test b/test/doc/transaction-status-1.test new file mode 100644 index 00000000..4bdf893a --- /dev/null +++ b/test/doc/transaction-status-1.test @@ -0,0 +1,19 @@ +reg --columns=60 food +<<< +2009/10/31 * Panera Bread + Expenses:Food $4.50 + Assets + +2009/11/01 ! Panera Bread + Expenses:Food $4.50 + Assets + +2009/11/02 Panera Bread + Expenses:Food $4.50 + Assets +>>>1 +09-Oct-31 Panera Bread Expenses:Food $4.50 $4.50 +09-Nov-01 Panera Bread Expenses:Food $4.50 $9.00 +09-Nov-02 Panera Bread Expenses:Food $4.50 $13.50 +>>>2 +=== 0 diff --git a/test/doc/transaction-status-2.test b/test/doc/transaction-status-2.test new file mode 100644 index 00000000..dbbb04ae --- /dev/null +++ b/test/doc/transaction-status-2.test @@ -0,0 +1,17 @@ +reg --columns=60 food --cleared +<<< +2009/10/31 * Panera Bread + Expenses:Food $4.50 + Assets + +2009/11/01 ! Panera Bread + Expenses:Food $4.50 + Assets + +2009/11/02 Panera Bread + Expenses:Food $4.50 + Assets +>>>1 +09-Oct-31 Panera Bread Expenses:Food $4.50 $4.50 +>>>2 +=== 0 diff --git a/test/doc/transaction-status-3.test b/test/doc/transaction-status-3.test new file mode 100644 index 00000000..1e6467ef --- /dev/null +++ b/test/doc/transaction-status-3.test @@ -0,0 +1,18 @@ +reg --columns=60 food --uncleared +<<< +2009/10/31 * Panera Bread + Expenses:Food $4.50 + Assets + +2009/11/01 ! Panera Bread + Expenses:Food $4.50 + Assets + +2009/11/02 Panera Bread + Expenses:Food $4.50 + Assets +>>>1 +09-Nov-01 Panera Bread Expenses:Food $4.50 $4.50 +09-Nov-02 Panera Bread Expenses:Food $4.50 $9.00 +>>>2 +=== 0 diff --git a/test/doc/transaction-status-4.test b/test/doc/transaction-status-4.test new file mode 100644 index 00000000..5275eec3 --- /dev/null +++ b/test/doc/transaction-status-4.test @@ -0,0 +1,17 @@ +reg --columns=60 food --pending +<<< +2009/10/31 * Panera Bread + Expenses:Food $4.50 + Assets + +2009/11/01 ! Panera Bread + Expenses:Food $4.50 + Assets + +2009/11/02 Panera Bread + Expenses:Food $4.50 + Assets +>>>1 +09-Nov-01 Panera Bread Expenses:Food $4.50 $4.50 +>>>2 +=== 0 diff --git a/tools/Makefile.am b/tools/Makefile.am index 13ea4e7f..d84229f4 100644 --- a/tools/Makefile.am +++ b/tools/Makefile.am @@ -247,7 +247,7 @@ endif TESTS = if HAVE_PYTHON -TESTS += RegressTests BaselineTests ConfirmTests GenerateTests +TESTS += RegressTests BaselineTests DocTests ConfirmTests GenerateTests endif if HAVE_CPPUNIT @@ -381,6 +381,14 @@ BaselineTests: $(srcdir)/test/RegressTests.py echo "$(PYTHON) $(srcdir)/test/RegressTests.py $(top_builddir)/ledger$(EXEEXT) $(srcdir)/test/baseline \"\$$@\"" > $@ chmod 755 $@ +DocTests_SOURCES = test/RegressTests.py + +EXTRA_DIST += test/doc + +DocTests: $(srcdir)/test/RegressTests.py + echo "$(PYTHON) $(srcdir)/test/RegressTests.py $(top_builddir)/ledger$(EXEEXT) $(srcdir)/test/doc \"\$$@\"" > $@ + chmod 755 $@ + ConfirmTests_SOURCES = test/ConfirmTests.py EXTRA_DIST += test/input @@ -424,10 +432,12 @@ endif fullcheck: cppunittests @$(top_builddir)/RegressTests --verify @$(top_builddir)/BaselineTests --verify + @$(top_builddir)/DocTests --verify @$(top_builddir)/ConfirmTests --verify @$(top_builddir)/GenerateTests --verify @$(top_builddir)/RegressTests --gmalloc @$(top_builddir)/BaselineTests --gmalloc + @$(top_builddir)/DocTests --gmalloc # @$(top_builddir)/ConfirmTests --gmalloc # @$(top_builddir)/GenerateTests --gmalloc |