mirror of
https://github.com/simonmichael/hledger.git
synced 2024-11-08 07:09:28 +03:00
convert a few doctests to shell test format
This commit is contained in:
parent
6b2e735ba1
commit
9bdb1ab0ec
20
tests/missing-real-and-virtual-amt.test
Normal file
20
tests/missing-real-and-virtual-amt.test
Normal file
@ -0,0 +1,20 @@
|
||||
register
|
||||
<<<
|
||||
2009/6/24 carwash
|
||||
equity:draw:personal:transportation:car:carwash $3.50
|
||||
assets:cash
|
||||
[expenses:car] $3.50
|
||||
[simon]
|
||||
>>>
|
||||
>>>2
|
||||
"-" (line 6, column 1):
|
||||
unexpected end of input
|
||||
could not balance this transaction, amounts do not add up to zero:
|
||||
2009/06/24 carwash
|
||||
equity:draw:personal:transportatio $3.50
|
||||
assets:cash
|
||||
[expenses:car] $3.50
|
||||
[simon]
|
||||
|
||||
|
||||
===0
|
9
tests/sample-balance-depth.test
Normal file
9
tests/sample-balance-depth.test
Normal file
@ -0,0 +1,9 @@
|
||||
-f sample.ledger balance --depth 1
|
||||
<<<
|
||||
>>>
|
||||
$-1 assets
|
||||
$2 expenses
|
||||
$-2 income
|
||||
$1 liabilities
|
||||
>>>2
|
||||
===0
|
11
tests/sample-balance-o.test
Normal file
11
tests/sample-balance-o.test
Normal file
@ -0,0 +1,11 @@
|
||||
-f sample.ledger balance o
|
||||
<<<
|
||||
>>>1
|
||||
$1 expenses:food
|
||||
$-2 income
|
||||
$-1 gifts
|
||||
$-1 salary
|
||||
--------------------
|
||||
$-1
|
||||
>>>2
|
||||
===0
|
15
tests/sample-balance.test
Normal file
15
tests/sample-balance.test
Normal file
@ -0,0 +1,15 @@
|
||||
-f sample.ledger balance
|
||||
<<<
|
||||
>>>1
|
||||
$-1 assets
|
||||
$1 bank:saving
|
||||
$-2 cash
|
||||
$2 expenses
|
||||
$1 food
|
||||
$1 supplies
|
||||
$-2 income
|
||||
$-1 gifts
|
||||
$-1 salary
|
||||
$1 liabilities:debts
|
||||
>>>2
|
||||
===0
|
17
tests/unbalanced.test
Normal file
17
tests/unbalanced.test
Normal file
@ -0,0 +1,17 @@
|
||||
; shouldn't exit code be 1 ?
|
||||
register
|
||||
<<<
|
||||
2009/1/1 a
|
||||
b 1.1
|
||||
c -1
|
||||
>>>
|
||||
>>>2
|
||||
"-" (line 4, column 1):
|
||||
unexpected end of input
|
||||
could not balance this transaction, amounts do not add up to zero:
|
||||
2009/01/01 a
|
||||
b 1.1
|
||||
c -1
|
||||
|
||||
|
||||
===0
|
Loading…
Reference in New Issue
Block a user