summaryrefslogtreecommitdiff
path: root/test/regress/F559EC12.test
diff options
context:
space:
mode:
authorJohn Wiegley <johnw@newartisans.com>2009-06-28 15:53:46 +0100
committerJohn Wiegley <johnw@newartisans.com>2009-06-28 15:53:46 +0100
commite8f315f00d0874e2afdee45525c4ce96d0768336 (patch)
tree2f8c3273fc1e5567e2326a66b4017b9f7c39caa2 /test/regress/F559EC12.test
parent6e582a87774140337b56568358e27e7cfe09514c (diff)
downloadfork-ledger-e8f315f00d0874e2afdee45525c4ce96d0768336.tar.gz
fork-ledger-e8f315f00d0874e2afdee45525c4ce96d0768336.tar.bz2
fork-ledger-e8f315f00d0874e2afdee45525c4ce96d0768336.zip
Correctly align amounts formatted as "%12(amount)"
Diffstat (limited to 'test/regress/F559EC12.test')
-rw-r--r--test/regress/F559EC12.test35
1 files changed, 35 insertions, 0 deletions
diff --git a/test/regress/F559EC12.test b/test/regress/F559EC12.test
new file mode 100644
index 00000000..7900b60d
--- /dev/null
+++ b/test/regress/F559EC12.test
@@ -0,0 +1,35 @@
+format "%-12(scrub(amount))"
+<<<
+>>>1
+--- Context is first posting of the following transaction ---
+2004/05/27 Book Store
+ Expenses:Books 20 BOOK @ $10
+ Liabilities:MasterCard $-200.00
+
+--- Input format string ---
+%-12(scrub(amount))
+
+--- Format elements ---
+Element: EXPR flags: 0x1 min: 12 max: 0 expr: scrub(amount)
+
+--- Formatted string ---
+"20 BOOK "
+>>>2
+=== 0
+format "%12(scrub(amount))"
+>>>1
+--- Context is first posting of the following transaction ---
+2004/05/27 Book Store
+ Expenses:Books 20 BOOK @ $10
+ Liabilities:MasterCard $-200.00
+
+--- Input format string ---
+%12(scrub(amount))
+
+--- Format elements ---
+Element: EXPR flags: 0x0 min: 12 max: 0 expr: scrub(amount)
+
+--- Formatted string ---
+" 20 BOOK"
+>>>2
+=== 0