hledger/tests/journal
Simon Michael 0b380971f7 journal: require a decimal point in commodity/format/D directives
A commodity directive that doesn't specify the decimal point character
increases ambiguity and the chance of misparsing numbers, especially
as it overrides all style information inferred from the journal amounts.
In some cases it caused amounts with a decimal point to be parsed as if
with a digit group separator so 1.234 became 1234.

We could augment it with extra info from the journal amounts, when available,
but it would still be possible to be ambiguous, and that won't be obvious.

A commodity directive is what we recommend to nail down the style.
It seems the simple and really only way to do this reliably is to require
an explicit decimal point character. Most folks probably do this already.

Unfortunately, it makes another potential incompatiblity with ledger and
beancount journals. But the error message will be clear and easy to
work around.
2018-04-20 21:56:06 -07:00
..
a.timeclock func. test for 320 2016-05-18 13:10:41 -07:00
amounts.test lib: add test for an amount parsing issue 2017-08-03 16:58:54 -07:00
b.timedot func. test for 320 2016-05-18 13:10:41 -07:00
balance-assertions.test Rewrite of BalanceAssertion type to track its source position. 2017-10-16 13:25:03 -07:00
blank-description.test tests: make functional tests use "hledger" again 2015-07-12 12:29:53 -07:00
comments.test journal: clarify that txn/posting comments must start with semicolon 2017-11-01 08:04:25 -07:00
commodities.test lib: keep amounts aligned when rendering a transaction with posting flags 2017-06-04 21:26:18 -07:00
commodity-styles.test test numbering 2016-05-13 22:10:23 -07:00
dates.test lib: keep amounts aligned when rendering a transaction with posting flags 2017-06-04 21:26:18 -07:00
default-commodity.test lib: keep amounts aligned when rendering a transaction with posting flags 2017-06-04 21:26:18 -07:00
directives.test journal: limit scope of directives backtracking 2017-11-27 14:32:48 -08:00
include.test lib: keep amounts aligned when rendering a transaction with posting flags 2017-06-04 21:26:18 -07:00
market-prices.test uses today's prices, not those of last txn date, for -V (fix #683,#648) 2017-12-29 21:42:59 -08:00
numbers.test journal: require a decimal point in commodity/format/D directives 2018-04-20 21:56:06 -07:00
parens-in-account-name.test lib: keep amounts aligned when rendering a transaction with posting flags 2017-06-04 21:26:18 -07:00
parse-sample-journal.test tests: make functional tests use "hledger" again 2015-07-12 12:29:53 -07:00
posting-dates.test Replace Parsec with Megaparsec (see #289) (#366) 2016-07-29 08:57:10 -07:00
precision.test journal: infer and balance amounts with standard amount styles (fix #737) 2018-04-20 13:40:05 -07:00
scientific.test scientific notation test notes (#704, #706) 2018-03-31 02:42:37 +01:00
status.journal lib, cli: -U/--uncleared no longer matches pending things (#564) 2017-06-15 19:16:39 -07:00
status.test rename "uncleared" status to "unmarked" and --uncleared to --unmarked (#564) 2017-06-15 19:16:39 -07:00
tags.test lib: keep amounts aligned when rendering a transaction with posting flags 2017-06-04 21:26:18 -07:00
transaction-prices.test lib: keep amounts aligned when rendering a transaction with posting flags 2017-06-04 21:26:18 -07:00
unbalanced.test tests: make functional tests use "hledger" again 2015-07-12 12:29:53 -07:00
virtual-postings.test Balance Assignments and accounts resetting (#438) 2016-12-10 07:04:48 -08:00