summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorDonald Lam <brainy.runt@gmail.com>2023-01-15 16:19:18 -0800
committerMartin Michlmayr <tbm@cyrius.com>2023-01-25 11:15:59 +0800
commit0925eb53b4c94cff4843b6ed6e1c955d3ba1e2a0 (patch)
treefcb94078ba7bf3f654bf91e2ba03491916d9c4bf /test
parentdfae685fbc7a445367d71e31a385d3e60b624f98 (diff)
downloadfork-ledger-0925eb53b4c94cff4843b6ed6e1c955d3ba1e2a0.tar.gz
fork-ledger-0925eb53b4c94cff4843b6ed6e1c955d3ba1e2a0.tar.bz2
fork-ledger-0925eb53b4c94cff4843b6ed6e1c955d3ba1e2a0.zip
Rename quoted_rfc4180 to quoted_rfc, to avoid parser quirk
Ledger's expression parser considers quoted_rfc4180 to be an amount (quantity 4180 of commodity "quoted_rfc"). Fixes #2007.
Diffstat (limited to 'test')
-rw-r--r--test/baseline/opt-csv-format4180.test7
-rw-r--r--test/baseline/opt-csv-formatq.test7
2 files changed, 14 insertions, 0 deletions
diff --git a/test/baseline/opt-csv-format4180.test b/test/baseline/opt-csv-format4180.test
new file mode 100644
index 00000000..adebb09f
--- /dev/null
+++ b/test/baseline/opt-csv-format4180.test
@@ -0,0 +1,7 @@
+2023/01/09 John's Hardware - 2" rubber nails
+ Expenses:DIY $1.00
+ Assets:Cash
+
+test csv --csv-format='%(quoted_rfc(payee))\n' expenses
+"John's Hardware - 2"" rubber nails"
+end test
diff --git a/test/baseline/opt-csv-formatq.test b/test/baseline/opt-csv-formatq.test
new file mode 100644
index 00000000..ab264a7c
--- /dev/null
+++ b/test/baseline/opt-csv-formatq.test
@@ -0,0 +1,7 @@
+2023/01/09 John's Hardware - 2" rubber nails
+ Expenses:DIY $1.00
+ Assets:Cash
+
+test csv --csv-format='%(quoted(payee))\n' expenses
+"John's Hardware - 2\" rubber nails"
+end test