summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
Diffstat (limited to 'test')
-rwxr-xr-xtest/DocTests.py2
-rw-r--r--test/baseline/opt-trace.test15
2 files changed, 16 insertions, 1 deletions
diff --git a/test/DocTests.py b/test/DocTests.py
index be28fae1..dbd24634 100755
--- a/test/DocTests.py
+++ b/test/DocTests.py
@@ -114,7 +114,7 @@ class DocTests:
if command[0] == '$': command.remove('$')
index = command.index('ledger')
command[index] = self.ledger
- for i,argument in enumerate('--init-file /dev/null --columns 80'.split()):
+ for i,argument in enumerate('--args-only --columns 80'.split()):
command.insert(index+i+1, argument)
try:
diff --git a/test/baseline/opt-trace.test b/test/baseline/opt-trace.test
new file mode 100644
index 00000000..9034018e
--- /dev/null
+++ b/test/baseline/opt-trace.test
@@ -0,0 +1,15 @@
+2007/02/02 RD VMMXX
+ Assets:Investments:Vanguard:VMMXX 0.350 VMMXX @ $1.00
+ Income:Dividends:Vanguard:VMMXX $-0.35
+
+; Using values with two or more digits as the argument to the --trace option
+; resulted in a segmentation fault.
+; Since ledger prints debugging information to stderr when the --trace option
+; was given and that debugging information contains timing information, e.g. [1ms]
+; which is likely to differ on each test run, this test only checks that ledger
+; does not crash when the --trace options was specified.
+test reg --trace 10 2>/dev/null
+07-Feb-02 RD VMMXX As:Inves:Vanguar:VMMXX 0.350 VMMXX 0.350 VMMXX
+ In:Divid:Vanguar:VMMXX $-0.35 $-0.35
+ 0.350 VMMXX
+end test