From 30fb0e0dc8972dcde0c4e765c5ab7864f69841a4 Mon Sep 17 00:00:00 2001 From: Ben Sima Date: Fri, 19 Feb 2021 10:42:02 -0500 Subject: Formatting, and add a warning to 'require' --- Alpha.hs | 1 + Biz/Cli.hs | 2 +- Biz/Test.hs | 1 - 3 files changed, 2 insertions(+), 2 deletions(-) diff --git a/Alpha.hs b/Alpha.hs index 8fdca51..9feb123 100644 --- a/Alpha.hs +++ b/Alpha.hs @@ -213,6 +213,7 @@ capitalize str = (Char.toUpper <| List.head str) : (Char.toLower String lowercase str = [Char.toLower c | c <- str] +{-# WARNING require "'require' remains in code" #-} require :: Text -> Maybe a -> a require _ (Just x) = x require s Nothing = panic <| s <> " not found" diff --git a/Biz/Cli.hs b/Biz/Cli.hs index a456fcc..05d81ac 100644 --- a/Biz/Cli.hs +++ b/Biz/Cli.hs @@ -18,9 +18,9 @@ module Biz.Cli where import Alpha +import qualified Biz.Test as Test import qualified System.Console.Docopt as Docopt import qualified System.Environment as Environment -import qualified Biz.Test as Test data Plan cfg = Plan { help :: Docopt.Docopt, diff --git a/Biz/Test.hs b/Biz/Test.hs index 994a7ce..fefa85d 100644 --- a/Biz/Test.hs +++ b/Biz/Test.hs @@ -35,7 +35,6 @@ run tree = do exitFailure Just act -> act +> \ok -> if ok then exitSuccess else exitFailure - group :: Tasty.TestName -> [Tasty.TestTree] -> Tasty.TestTree group = Tasty.testGroup -- cgit v1.2.3