Skip to content

Commit

Permalink
dev: disable doctest testing error output, color breaks it
Browse files Browse the repository at this point in the history
  • Loading branch information
simonmichael committed Dec 20, 2024
1 parent aefa4e8 commit 1a5353b
Showing 1 changed file with 5 additions and 3 deletions.
8 changes: 5 additions & 3 deletions hledger-lib/Hledger/Reports/ReportOptions.hs
Original file line number Diff line number Diff line change
Expand Up @@ -88,7 +88,6 @@ import Hledger.Query
import Hledger.Utils
import Data.Function ((&))


-- | What to calculate for each cell in a balance report.
-- "Balance report types -> Calculation type" in the hledger manual.
data BalanceCalculation =
Expand Down Expand Up @@ -890,10 +889,13 @@ makeHledgerClassyLenses ''ReportSpec
-- Left "This regular expression is invalid or unsupported, please correct it:\n(assets"
-- >>> _rsQuery $ set querystring ["assets"] defreportspec
-- Acct (RegexpCI "assets")
-- >>> _rsQuery $ set querystring ["(assets"] defreportspec
-- *** Exception: Error: Updating ReportSpec failed: try using overEither instead of over or setEither instead of set
-- >>> _rsQuery $ set period (MonthPeriod 2021 08) defreportspec
-- Date DateSpan 2021-08
--
-- XXX testing error output isn't working since adding color to it:
-- > import System.Environment
-- > setEnv "NO_COLOR" "1" >> return (_rsQuery $ set querystring ["(assets"] defreportspec)
-- *** Exception: Error: Updating ReportSpec failed: try using overEither instead of over or setEither instead of set
class HasReportOptsNoUpdate a => HasReportOpts a where
reportOpts :: ReportableLens' a ReportOpts
reportOpts = reportOptsNoUpdate
Expand Down

0 comments on commit 1a5353b

Please sign in to comment.