diff --git a/hledger-lib/Hledger.hs b/hledger-lib/Hledger.hs index c8e638ac9..ba25a5d1b 100644 --- a/hledger-lib/Hledger.hs +++ b/hledger-lib/Hledger.hs @@ -2,7 +2,7 @@ module Hledger ( module X - ,easytests_Hledger + ,tests_Hledger ) where @@ -12,10 +12,10 @@ import Hledger.Reports as X import Hledger.Query as X import Hledger.Utils as X -easytests_Hledger = tests "Hledger" [ - easytests_Data - ,easytests_Query - ,easytests_Read - ,easytests_Reports - ,easytests_Utils +tests_Hledger = tests "Hledger" [ + tests_Data + ,tests_Query + ,tests_Read + ,tests_Reports + ,tests_Utils ] diff --git a/hledger-lib/Hledger/Data.hs b/hledger-lib/Hledger/Data.hs index 56ff5b7cd..990ed753d 100644 --- a/hledger-lib/Hledger/Data.hs +++ b/hledger-lib/Hledger/Data.hs @@ -26,7 +26,7 @@ module Hledger.Data ( module Hledger.Data.Transaction, module Hledger.Data.TransactionModifier, module Hledger.Data.Types, - easytests_Data + tests_Data ) where @@ -49,13 +49,13 @@ import Hledger.Data.TransactionModifier import Hledger.Data.Types import Hledger.Utils.Test -easytests_Data = tests "Data" [ - easytests_AccountName - ,easytests_Amount - ,easytests_Journal - ,easytests_Ledger - ,easytests_Posting - ,easytests_StringFormat - ,easytests_Timeclock - ,easytests_Transaction +tests_Data = tests "Data" [ + tests_AccountName + ,tests_Amount + ,tests_Journal + ,tests_Ledger + ,tests_Posting + ,tests_StringFormat + ,tests_Timeclock + ,tests_Transaction ] diff --git a/hledger-lib/Hledger/Data/AccountName.hs b/hledger-lib/Hledger/Data/AccountName.hs index c4fe77eaa..74f0fdb5b 100644 --- a/hledger-lib/Hledger/Data/AccountName.hs +++ b/hledger-lib/Hledger/Data/AccountName.hs @@ -36,7 +36,7 @@ module Hledger.Data.AccountName ( ,subAccountNamesFrom ,topAccountNames ,unbudgetedAccountName - ,easytests_AccountName + ,tests_AccountName ) where @@ -226,7 +226,7 @@ accountRegexToAccountName = T.pack . regexReplace "^\\^(.*?)\\(:\\|\\$\\)$" "\\1 --isAccountRegex :: String -> Bool --isAccountRegex s = take 1 s == "^" && take 5 (reverse s) == ")$|:(" -easytests_AccountName = tests "AccountName" [ +tests_AccountName = tests "AccountName" [ tests "accountNameTreeFrom" [ accountNameTreeFrom ["a"] `is` Node "root" [Node "a" []] ,accountNameTreeFrom ["a","b"] `is` Node "root" [Node "a" [], Node "b" []] diff --git a/hledger-lib/Hledger/Data/Amount.hs b/hledger-lib/Hledger/Data/Amount.hs index bba0bc545..7fbeab7b1 100644 --- a/hledger-lib/Hledger/Data/Amount.hs +++ b/hledger-lib/Hledger/Data/Amount.hs @@ -114,7 +114,7 @@ module Hledger.Data.Amount ( canonicaliseMixedAmount, -- * misc. ltraceamount, - easytests_Amount + tests_Amount ) where import Data.Char (isDigit) @@ -671,7 +671,7 @@ mixedAmountValue j d (Mixed as) = Mixed $ map (amountValue j d) as ------------------------------------------------------------------------------- -- tests -easytests_Amount = tests "Amount" [ +tests_Amount = tests "Amount" [ tests "Amount" [ tests "costOfAmount" [ diff --git a/hledger-lib/Hledger/Data/Journal.hs b/hledger-lib/Hledger/Data/Journal.hs index cea1f10c9..9feb76825 100644 --- a/hledger-lib/Hledger/Data/Journal.hs +++ b/hledger-lib/Hledger/Data/Journal.hs @@ -68,7 +68,7 @@ module Hledger.Data.Journal ( journalUntieTransactions, -- * Tests samplejournal, - easytests_Journal, + tests_Journal, ) where import Control.Applicative (Const(..)) @@ -1060,7 +1060,7 @@ Right samplejournal = journalBalanceTransactions False $ ] } -easytests_Journal = tests "Journal" [ +tests_Journal = tests "Journal" [ test "journalDateSpan" $ journalDateSpan True nulljournal{ diff --git a/hledger-lib/Hledger/Data/Ledger.hs b/hledger-lib/Hledger/Data/Ledger.hs index a97848f30..49ac38c63 100644 --- a/hledger-lib/Hledger/Data/Ledger.hs +++ b/hledger-lib/Hledger/Data/Ledger.hs @@ -21,7 +21,7 @@ module Hledger.Data.Ledger ( ,ledgerPostings ,ledgerDateSpan ,ledgerCommodities - ,easytests_Ledger + ,tests_Ledger ) where @@ -107,7 +107,7 @@ ledgerCommodities = M.keys . jinferredcommodities . ljournal -- tests -easytests_Ledger = tests "Ledger" [ +tests_Ledger = tests "Ledger" [ tests "ledgerFromJournal" [ (length $ ledgerPostings $ ledgerFromJournal Any nulljournal) `is` 0 diff --git a/hledger-lib/Hledger/Data/Posting.hs b/hledger-lib/Hledger/Data/Posting.hs index 583cf0420..cb0cc4d6b 100644 --- a/hledger-lib/Hledger/Data/Posting.hs +++ b/hledger-lib/Hledger/Data/Posting.hs @@ -54,7 +54,7 @@ module Hledger.Data.Posting ( showPosting, -- * misc. showComment, - easytests_Posting + tests_Posting ) where import Data.List @@ -293,7 +293,7 @@ aliasReplace (RegexAlias re repl) a = T.pack $ regexReplaceCIMemo re repl $ T.un -- tests -easytests_Posting = tests "Posting" [ +tests_Posting = tests "Posting" [ tests "accountNamePostingType" [ accountNamePostingType "a" `is` RegularPosting diff --git a/hledger-lib/Hledger/Data/StringFormat.hs b/hledger-lib/Hledger/Data/StringFormat.hs index 2543a91a0..815af005b 100644 --- a/hledger-lib/Hledger/Data/StringFormat.hs +++ b/hledger-lib/Hledger/Data/StringFormat.hs @@ -10,7 +10,7 @@ module Hledger.Data.StringFormat ( , StringFormat(..) , StringFormatComponent(..) , ReportItemField(..) - , easytests_StringFormat + , tests_StringFormat ) where import Prelude () @@ -143,7 +143,7 @@ formatStringTester fs value expected = actual `is` expected FormatLiteral l -> formatString False Nothing Nothing l FormatField leftJustify min max _ -> formatString leftJustify min max value -easytests_StringFormat = tests "StringFormat" [ +tests_StringFormat = tests "StringFormat" [ tests "formatStringHelper" [ formatStringTester (FormatLiteral " ") "" " " diff --git a/hledger-lib/Hledger/Data/Timeclock.hs b/hledger-lib/Hledger/Data/Timeclock.hs index 1bcff2c85..8aa552edd 100644 --- a/hledger-lib/Hledger/Data/Timeclock.hs +++ b/hledger-lib/Hledger/Data/Timeclock.hs @@ -10,7 +10,7 @@ converted to 'Transactions' and queried like a ledger. module Hledger.Data.Timeclock ( timeclockEntriesToTransactions - ,easytests_Timeclock + ,tests_Timeclock ) where @@ -113,7 +113,7 @@ entryFromTimeclockInOut i o -- tests -easytests_Timeclock = tests "Timeclock" [ +tests_Timeclock = tests "Timeclock" [ do today <- io getCurrentDay now' <- io getCurrentTime diff --git a/hledger-lib/Hledger/Data/Transaction.hs b/hledger-lib/Hledger/Data/Transaction.hs index bac819371..20ed70464 100644 --- a/hledger-lib/Hledger/Data/Transaction.hs +++ b/hledger-lib/Hledger/Data/Transaction.hs @@ -43,7 +43,7 @@ module Hledger.Data.Transaction ( sourceFirstLine, showGenericSourcePos, -- * tests - easytests_Transaction + tests_Transaction ) where import Data.List @@ -442,7 +442,7 @@ postingSetTransaction t p = p{ptransaction=Just t} -- tests -easytests_Transaction = tests "Transaction" [ +tests_Transaction = tests "Transaction" [ tests "showTransactionUnelided" [ showTransactionUnelided nulltransaction `is` "0000/01/01\n\n" diff --git a/hledger-lib/Hledger/Query.hs b/hledger-lib/Hledger/Query.hs index 84932ff55..d8cdbb985 100644 --- a/hledger-lib/Hledger/Query.hs +++ b/hledger-lib/Hledger/Query.hs @@ -46,7 +46,7 @@ module Hledger.Query ( matchesMarketPrice, words'', -- * tests - easytests_Query + tests_Query ) where @@ -652,7 +652,7 @@ matchesMarketPrice _ _ = True -- tests -easytests_Query = tests "Query" [ +tests_Query = tests "Query" [ tests "simplifyQuery" [ (simplifyQuery $ Or [Acct "a"]) `is` (Acct "a") diff --git a/hledger-lib/Hledger/Read.hs b/hledger-lib/Hledger/Read.hs index 872446745..46f9ce4e3 100644 --- a/hledger-lib/Hledger/Read.hs +++ b/hledger-lib/Hledger/Read.hs @@ -29,7 +29,7 @@ module Hledger.Read ( module Hledger.Read.Common, -- * Tests - easytests_Read, + tests_Read, ) where @@ -307,10 +307,10 @@ tryReaders iopts mpath readers txt = firstSuccessOrFirstError [] readers -- tests -easytests_Read = tests "Read" [ - easytests_Common - ,easytests_CsvReader - ,easytests_JournalReader +tests_Read = tests "Read" [ + tests_Common + ,tests_CsvReader + ,tests_JournalReader ] --samplejournal = readJournal' $ T.unlines diff --git a/hledger-lib/Hledger/Read/Common.hs b/hledger-lib/Hledger/Read/Common.hs index d7ca5673b..a6b9dac3a 100644 --- a/hledger-lib/Hledger/Read/Common.hs +++ b/hledger-lib/Hledger/Read/Common.hs @@ -92,7 +92,7 @@ module Hledger.Read.Common ( singlespacep, -- * tests - easytests_Common, + tests_Common, ) where --- * imports @@ -1200,7 +1200,7 @@ match' p = do --- * tests -easytests_Common = tests "Common" [ +tests_Common = tests "Common" [ tests "amountp" [ test "basic" $ expectParseEq amountp "$47.18" (usd 47.18) diff --git a/hledger-lib/Hledger/Read/CsvReader.hs b/hledger-lib/Hledger/Read/CsvReader.hs index e0aceeaed..4a1f1453b 100644 --- a/hledger-lib/Hledger/Read/CsvReader.hs +++ b/hledger-lib/Hledger/Read/CsvReader.hs @@ -25,7 +25,7 @@ module Hledger.Read.CsvReader ( expandIncludes, transactionFromCsvRecord, -- * Tests - easytests_CsvReader, + tests_CsvReader, ) where import Prelude () @@ -832,7 +832,7 @@ parseDateWithFormatOrDefaultFormats mformat s = firstJust $ map parsewith format -------------------------------------------------------------------------------- -- tests -easytests_CsvReader = tests "CsvReader" [ +tests_CsvReader = tests "CsvReader" [ tests "parseCsvRules" [ test "empty file" $ parseCsvRules "unknown" "" `is` Right rules diff --git a/hledger-lib/Hledger/Read/JournalReader.hs b/hledger-lib/Hledger/Read/JournalReader.hs index a49984866..9d981e729 100644 --- a/hledger-lib/Hledger/Read/JournalReader.hs +++ b/hledger-lib/Hledger/Read/JournalReader.hs @@ -58,7 +58,7 @@ module Hledger.Read.JournalReader ( followingcommentp -- * Tests - ,easytests_JournalReader + ,tests_JournalReader ) where --- * imports @@ -576,7 +576,7 @@ postingp mTransactionYear = do --- * tests -easytests_JournalReader = tests "JournalReader" [ +tests_JournalReader = tests "JournalReader" [ let p = lift accountnamep :: JournalParser IO AccountName in tests "accountnamep" [ diff --git a/hledger-lib/Hledger/Reports.hs b/hledger-lib/Hledger/Reports.hs index d7ac7e358..d53dd379b 100644 --- a/hledger-lib/Hledger/Reports.hs +++ b/hledger-lib/Hledger/Reports.hs @@ -19,7 +19,7 @@ module Hledger.Reports ( module Hledger.Reports.BudgetReport, -- module Hledger.Reports.BalanceHistoryReport, -- * Tests - easytests_Reports + tests_Reports ) where @@ -34,12 +34,12 @@ import Hledger.Reports.BudgetReport -- import Hledger.Reports.BalanceHistoryReport import Hledger.Utils.Test -easytests_Reports = tests "Reports" [ - easytests_BalanceReport - ,easytests_BudgetReport - ,easytests_EntriesReport - ,easytests_MultiBalanceReports - ,easytests_PostingsReport - ,easytests_ReportOptions - ,easytests_TransactionsReports +tests_Reports = tests "Reports" [ + tests_BalanceReport + ,tests_BudgetReport + ,tests_EntriesReport + ,tests_MultiBalanceReports + ,tests_PostingsReport + ,tests_ReportOptions + ,tests_TransactionsReports ] diff --git a/hledger-lib/Hledger/Reports/BalanceReport.hs b/hledger-lib/Hledger/Reports/BalanceReport.hs index 27c7c11e7..d50fc491f 100644 --- a/hledger-lib/Hledger/Reports/BalanceReport.hs +++ b/hledger-lib/Hledger/Reports/BalanceReport.hs @@ -20,7 +20,7 @@ module Hledger.Reports.BalanceReport ( flatShowsExclusiveBalance, -- * Tests - easytests_BalanceReport + tests_BalanceReport ) where @@ -180,7 +180,7 @@ Right samplejournal2 = -- tests -easytests_BalanceReport = tests "BalanceReport" [ +tests_BalanceReport = tests "BalanceReport" [ tests "balanceReport" $ let (opts,journal) `gives` r = do diff --git a/hledger-lib/Hledger/Reports/BudgetReport.hs b/hledger-lib/Hledger/Reports/BudgetReport.hs index 01f6c6a0a..8b7337c1e 100644 --- a/hledger-lib/Hledger/Reports/BudgetReport.hs +++ b/hledger-lib/Hledger/Reports/BudgetReport.hs @@ -356,5 +356,5 @@ maybeAccountNameDrop opts a | flat_ opts = accountNameDrop (drop_ opts) a -- tests -easytests_BudgetReport = tests "BudgetReport" [ +tests_BudgetReport = tests "BudgetReport" [ ] diff --git a/hledger-lib/Hledger/Reports/EntriesReport.hs b/hledger-lib/Hledger/Reports/EntriesReport.hs index 85a5cb18b..9abdea7c7 100644 --- a/hledger-lib/Hledger/Reports/EntriesReport.hs +++ b/hledger-lib/Hledger/Reports/EntriesReport.hs @@ -10,7 +10,7 @@ module Hledger.Reports.EntriesReport ( EntriesReportItem, entriesReport, -- * Tests - easytests_EntriesReport + tests_EntriesReport ) where @@ -37,7 +37,7 @@ entriesReport opts q j = date = transactionDateFn opts ts = jtxns $ journalSelectingAmountFromOpts opts j -easytests_EntriesReport = tests "EntriesReport" [ +tests_EntriesReport = tests "EntriesReport" [ tests "entriesReport" [ test "not acct" $ (length $ entriesReport defreportopts (Not $ Acct "bank") samplejournal) `is` 1 ,test "date" $ (length $ entriesReport defreportopts (Date $ mkdatespan "2008/06/01" "2008/07/01") samplejournal) `is` 3 diff --git a/hledger-lib/Hledger/Reports/MultiBalanceReports.hs b/hledger-lib/Hledger/Reports/MultiBalanceReports.hs index 4f336aac3..f0907fc32 100644 --- a/hledger-lib/Hledger/Reports/MultiBalanceReports.hs +++ b/hledger-lib/Hledger/Reports/MultiBalanceReports.hs @@ -16,7 +16,7 @@ module Hledger.Reports.MultiBalanceReports ( tableAsText, -- -- * Tests - easytests_MultiBalanceReports + tests_MultiBalanceReports ) where @@ -302,7 +302,7 @@ tableAsText (ReportOpts{pretty_tables_ = pretty}) showcell = -- tests -easytests_MultiBalanceReports = tests "MultiBalanceReports" [ +tests_MultiBalanceReports = tests "MultiBalanceReports" [ let (opts,journal) `gives` r = do let (eitems, etotal) = r diff --git a/hledger-lib/Hledger/Reports/PostingsReport.hs b/hledger-lib/Hledger/Reports/PostingsReport.hs index bbe387f6e..1aec322dc 100644 --- a/hledger-lib/Hledger/Reports/PostingsReport.hs +++ b/hledger-lib/Hledger/Reports/PostingsReport.hs @@ -12,7 +12,7 @@ module Hledger.Reports.PostingsReport ( mkpostingsReportItem, -- * Tests - easytests_PostingsReport + tests_PostingsReport ) where @@ -217,7 +217,7 @@ summarisePostingsInDateSpan (DateSpan b e) wd depth showempty ps -- tests -easytests_PostingsReport = tests "PostingsReport" [ +tests_PostingsReport = tests "PostingsReport" [ tests "postingsReport" $ let (query, journal) `gives` n = (length $ snd $ postingsReport defreportopts query journal) `is` n diff --git a/hledger-lib/Hledger/Reports/ReportOptions.hs b/hledger-lib/Hledger/Reports/ReportOptions.hs index 235a96715..271060386 100644 --- a/hledger-lib/Hledger/Reports/ReportOptions.hs +++ b/hledger-lib/Hledger/Reports/ReportOptions.hs @@ -33,7 +33,7 @@ module Hledger.Reports.ReportOptions ( specifiedStartDate, specifiedEndDate, - easytests_ReportOptions + tests_ReportOptions ) where @@ -420,7 +420,7 @@ specifiedEndDate ropts = snd <$> specifiedStartEndDates ropts -- tests -easytests_ReportOptions = tests "ReportOptions" [ +tests_ReportOptions = tests "ReportOptions" [ tests "queryFromOpts" [ (queryFromOpts nulldate defreportopts) `is` Any ,(queryFromOpts nulldate defreportopts{query_="a"}) `is` (Acct "a") diff --git a/hledger-lib/Hledger/Reports/TransactionsReports.hs b/hledger-lib/Hledger/Reports/TransactionsReports.hs index 4788827aa..ff8a712ab 100644 --- a/hledger-lib/Hledger/Reports/TransactionsReports.hs +++ b/hledger-lib/Hledger/Reports/TransactionsReports.hs @@ -23,7 +23,7 @@ module Hledger.Reports.TransactionsReports ( accountTransactionsReport, transactionsReportByCommodity, transactionRegisterDate, - easytests_TransactionsReports + tests_TransactionsReports ) where @@ -278,5 +278,5 @@ filterTransactionsReportByCommodity c (label,items) = -- tests -easytests_TransactionsReports = tests "TransactionsReports" [ +tests_TransactionsReports = tests "TransactionsReports" [ ] diff --git a/hledger-lib/Hledger/Utils.hs b/hledger-lib/Hledger/Utils.hs index df43a9651..365454710 100644 --- a/hledger-lib/Hledger/Utils.hs +++ b/hledger-lib/Hledger/Utils.hs @@ -217,6 +217,6 @@ sequence' ms = do mapM' :: Monad f => (a -> f b) -> [a] -> f [b] mapM' f = sequence' . map f -easytests_Utils = tests "Utils" [ - easytests_Text +tests_Utils = tests "Utils" [ + tests_Text ] diff --git a/hledger-lib/Hledger/Utils/Test.hs b/hledger-lib/Hledger/Utils/Test.hs index 08a69d0d9..208d5e6ef 100644 --- a/hledger-lib/Hledger/Utils/Test.hs +++ b/hledger-lib/Hledger/Utils/Test.hs @@ -6,7 +6,7 @@ module Hledger.Utils.Test ( HasCallStack ,module EasyTest - ,runEasyTests + ,runEasytests ,tests ,_tests ,test @@ -70,20 +70,21 @@ tests name = E.scope name . E.tests _tests :: T.Text -> [E.Test ()] -> E.Test () _tests _name = (E.skip >>) . E.tests --- | Run some easytests, returning True if there was a problem. Catches ExitCode. --- With arguments, runs only tests in the scope named by the first argument --- (case sensitive). +-- | Run some easytest tests, catching easytest's ExitCode exception, +-- returning True if there was a problem. +-- With arguments, runs only the scope (or single test) named by the first argument +-- (exact, case sensitive). -- If there is a second argument, it should be an integer and will be used -- as the seed for randomness. -runEasyTests :: [String] -> E.Test () -> IO Bool -runEasyTests args easytests = (do +runEasytests :: [String] -> E.Test () -> IO Bool +runEasytests args tests = (do case args of - [] -> E.run easytests - [a] -> E.runOnly (T.pack a) easytests + [] -> E.run tests + [a] -> E.runOnly (T.pack a) tests a:b:_ -> do case readMay b :: Maybe Int of Nothing -> error' "the second argument should be an integer (a seed for easytest)" - Just seed -> E.rerunOnly seed (T.pack a) easytests + Just seed -> E.rerunOnly seed (T.pack a) tests return False ) `catch` (\(_::ExitCode) -> return True) diff --git a/hledger-lib/Hledger/Utils/Text.hs b/hledger-lib/Hledger/Utils/Text.hs index e84013aea..d363a5d81 100644 --- a/hledger-lib/Hledger/Utils/Text.hs +++ b/hledger-lib/Hledger/Utils/Text.hs @@ -55,7 +55,7 @@ module Hledger.Utils.Text textPadLeftWide, textPadRightWide, -- -- * tests - easytests_Text + tests_Text ) where @@ -420,7 +420,7 @@ textWidth s = maximum $ map (T.foldr (\a b -> charWidth a + b) 0) $ T.lines s -- | otherwise -> 1 -easytests_Text = tests "Text" [ +tests_Text = tests "Text" [ tests "quoteIfSpaced" [ quoteIfSpaced "a'a" `is` "a'a" ,quoteIfSpaced "a\"a" `is` "a\"a" diff --git a/hledger-lib/test/easytests.hs b/hledger-lib/test/easytests.hs index 5e4b3d1bf..17c906e0b 100644 --- a/hledger-lib/test/easytests.hs +++ b/hledger-lib/test/easytests.hs @@ -2,4 +2,4 @@ Run hledger-lib's easytest tests using the easytest runner. -} import Hledger -main = run easytests_Hledger +main = run tests_Hledger diff --git a/hledger/Hledger/Cli.hs b/hledger/Hledger/Cli.hs index 26a00411f..57ed1c755 100644 --- a/hledger/Hledger/Cli.hs +++ b/hledger/Hledger/Cli.hs @@ -16,7 +16,7 @@ module Hledger.Cli ( module Hledger.Cli.Utils, module Hledger.Cli.Version, module Hledger, - easytests_Cli, + tests_Cli, module System.Console.CmdArgs.Explicit ) where @@ -29,7 +29,7 @@ import Hledger.Cli.DocFiles import Hledger.Cli.Utils import Hledger.Cli.Version -easytests_Cli = tests "Cli" [ - easytests_Hledger - ,easytests_Commands +tests_Cli = tests "Cli" [ + tests_Hledger + ,tests_Commands ] diff --git a/hledger/Hledger/Cli/Commands.hs b/hledger/Hledger/Cli/Commands.hs index 5f5c27272..24f9e3abe 100644 --- a/hledger/Hledger/Cli/Commands.hs +++ b/hledger/Hledger/Cli/Commands.hs @@ -12,7 +12,7 @@ module Hledger.Cli.Commands ( ,builtinCommands ,builtinCommandNames ,printCommandsList - ,easytests_Commands + ,tests_Commands ,module Hledger.Cli.Commands.Accounts ,module Hledger.Cli.Commands.Activity ,module Hledger.Cli.Commands.Add @@ -240,14 +240,14 @@ FLAGS testcmd :: CliOpts -> Journal -> IO () testcmd opts _undefined = do let args = words' $ query_ $ reportopts_ opts - e <- runEasyTests args $ EasyTest.tests [easytests_Hledger, easytests_Commands] + e <- runEasytests args $ EasyTest.tests [tests_Hledger, tests_Commands] if e then exitFailure else exitSuccess -- unit tests of hledger command-line executable -easytests_Commands = tests "Commands" [ - easytests_Balance - ,easytests_Register +tests_Commands = tests "Commands" [ + tests_Balance + ,tests_Register -- some more tests easiest to define here: diff --git a/hledger/Hledger/Cli/Commands/Balance.hs b/hledger/Hledger/Cli/Commands/Balance.hs index d01123583..40ec3c42d 100644 --- a/hledger/Hledger/Cli/Commands/Balance.hs +++ b/hledger/Hledger/Cli/Commands/Balance.hs @@ -247,7 +247,7 @@ module Hledger.Cli.Commands.Balance ( ,multiBalanceReportHtmlRows ,balanceReportAsTable ,balanceReportTableAsText - ,easytests_Balance + ,tests_Balance ) where import Control.Monad (when) @@ -630,7 +630,7 @@ balanceReportTableAsText ropts = tableAsText ropts showamt | otherwise = showMixedAmountOneLineWithoutPrice -easytests_Balance = tests "Balance" [ +tests_Balance = tests "Balance" [ tests "balanceReportAsText" [ test "unicode in balance layout" $ do diff --git a/hledger/Hledger/Cli/Commands/Register.hs b/hledger/Hledger/Cli/Commands/Register.hs index 4aa318a96..a414e62b9 100644 --- a/hledger/Hledger/Cli/Commands/Register.hs +++ b/hledger/Hledger/Cli/Commands/Register.hs @@ -12,7 +12,7 @@ module Hledger.Cli.Commands.Register ( ,postingsReportAsText ,postingsReportItemAsText -- ,showPostingWithBalanceForVty - ,easytests_Register + ,tests_Register ) where import Data.List @@ -191,7 +191,7 @@ postingsReportItemAsText opts preferredamtwidth preferredbalwidth (mdate, mendda -- tests -easytests_Register = tests "Register" [ +tests_Register = tests "Register" [ tests "postingsReportAsText" [ test "unicode in register layout" $ do