From f124007acfcf2f44fbff63fe54fd2598ae76012b Mon Sep 17 00:00:00 2001 From: Simon Michael Date: Mon, 20 Aug 2018 14:43:35 +0100 Subject: [PATCH] tests: dehyphenate test names --- hledger-lib/Hledger/Read/Common.hs | 6 +++--- hledger-lib/Hledger/Read/JournalReader.hs | 12 ++++++------ 2 files changed, 9 insertions(+), 9 deletions(-) diff --git a/hledger-lib/Hledger/Read/Common.hs b/hledger-lib/Hledger/Read/Common.hs index 83fd70851..ba7a36aef 100644 --- a/hledger-lib/Hledger/Read/Common.hs +++ b/hledger-lib/Hledger/Read/Common.hs @@ -1235,8 +1235,8 @@ tests_Hledger_Read_Common = TestList [ easytests_Common = tests "Common" [ tests "amountp" [ test "basic" $ expectParseEq amountp "$47.18" (usd 47.18) - ,test "ends-with-decimal-mark" $ expectParseEq amountp "$1." (usd 1 `withPrecision` 0) - ,test "unit-price" $ expectParseEq amountp "$10 @ €0.5" + ,test "ends with decimal mark" $ expectParseEq amountp "$1." (usd 1 `withPrecision` 0) + ,test "unit price" $ expectParseEq amountp "$10 @ €0.5" -- not precise enough: -- (usd 10 `withPrecision` 0 `at` (eur 0.5 `withPrecision` 1)) -- `withStyle` asdecimalpoint=Just '.' amount{ @@ -1250,7 +1250,7 @@ easytests_Common = tests "Common" [ ,astyle=amountstyle{asprecision=1, asdecimalpoint=Just '.'} } } - ,test "total-price" $ expectParseEq amountp "$10 @@ €5" + ,test "total price" $ expectParseEq amountp "$10 @@ €5" amount{ acommodity="$" ,aquantity=10 diff --git a/hledger-lib/Hledger/Read/JournalReader.hs b/hledger-lib/Hledger/Read/JournalReader.hs index a3b24b62f..c4f53aefd 100644 --- a/hledger-lib/Hledger/Read/JournalReader.hs +++ b/hledger-lib/Hledger/Read/JournalReader.hs @@ -618,7 +618,7 @@ easytests_JournalReader = tests "JournalReader" [ ,tests "periodictransactionp" [ - test "more-period-text-in-comment-after-one-space" $ expectParseEq periodictransactionp + test "more period text in comment after one space" $ expectParseEq periodictransactionp "~ monthly from 2018/6 ;In 2019 we will change this\n" nullperiodictransaction { ptperiodexpr = "monthly from 2018/6" @@ -633,7 +633,7 @@ easytests_JournalReader = tests "JournalReader" [ } -- TODO #807 - ,_test "more-period-text-in-description-after-two-spaces" $ expectParseEq periodictransactionp + ,_test "more period text in description after two spaces" $ expectParseEq periodictransactionp "~ monthly from 2018/6 In 2019 we will change this\n" nullperiodictransaction { ptperiodexpr = "monthly from 2018/6" @@ -642,7 +642,7 @@ easytests_JournalReader = tests "JournalReader" [ ,ptdescription = "In 2019 we will change this\n" } - ,_test "more-period-text-in-description-after-one-space" $ expectParseEq periodictransactionp + ,_test "more period text in description after one space" $ expectParseEq periodictransactionp "~ monthly from 2018/6 In 2019 we will change this\n" nullperiodictransaction { ptperiodexpr = "monthly from 2018/6" @@ -651,7 +651,7 @@ easytests_JournalReader = tests "JournalReader" [ ,ptdescription = "In 2019 we will change this\n" } - ,_test "Next-year-in-description" $ expectParseEq periodictransactionp + ,_test "Next year in description" $ expectParseEq periodictransactionp "~ monthly Next year blah blah\n" nullperiodictransaction { ptperiodexpr = "monthly" @@ -711,9 +711,9 @@ easytests_JournalReader = tests "JournalReader" [ ,tests "transactionp" [ - test "just-a-date" $ expectParseEq transactionp "2015/1/1\n" nulltransaction{tdate=fromGregorian 2015 1 1} + test "just a date" $ expectParseEq transactionp "2015/1/1\n" nulltransaction{tdate=fromGregorian 2015 1 1} - ,test "more-complex" $ expectParseEq transactionp + ,test "more complex" $ expectParseEq transactionp (T.unlines [ "2012/05/14=2012/05/15 (code) desc ; tcomment1", " ; tcomment2",