ci: Fix weeder not stopping CI on error
Removes dead code that was unnoticed Signed-off-by: Wolfgang Walther <walther@technowledgy.de>
This commit is contained in:
committed by
Wolfgang Walther
parent
0ea36fc039
commit
2fe2c9104b
+4
-1
@@ -133,7 +133,10 @@ let
|
||||
# build once before running all the tests
|
||||
${cabal-install}/bin/cabal v2-build ${devCabalOptions} exe:postgrest lib:postgrest test:spec test:querycost
|
||||
|
||||
${haskellPackages.weeder}/bin/weeder --config=./test/weeder.dhall || echo Found dead code: Check file list above.
|
||||
(
|
||||
trap 'echo Found dead code: Check file list above.' ERR ;
|
||||
${haskellPackages.weeder}/bin/weeder --config=./test/weeder.dhall
|
||||
)
|
||||
|
||||
# collect all tests
|
||||
HPCTIXFILE="$tmpdir"/io.tix \
|
||||
|
||||
@@ -5,14 +5,12 @@ import qualified Data.ByteString.Char8 as BS
|
||||
import qualified Data.ByteString.Lazy as BL
|
||||
import qualified Data.Map.Strict as M
|
||||
import qualified Data.Set as S
|
||||
import qualified System.IO.Error as E
|
||||
|
||||
import Data.Aeson (Value (..), decode, encode)
|
||||
import Data.CaseInsensitive (CI (..), original)
|
||||
import Data.List (lookup)
|
||||
import Data.List.NonEmpty (fromList)
|
||||
import Network.Wai.Test (SResponse (simpleBody, simpleHeaders, simpleStatus))
|
||||
import System.Environment (getEnv)
|
||||
import System.Process (readProcess)
|
||||
import Text.Regex.TDFA ((=~))
|
||||
|
||||
@@ -68,10 +66,6 @@ validateOpenApiResponse headers = do
|
||||
}
|
||||
|
||||
|
||||
getEnvVarWithDefault :: Text -> Text -> IO Text
|
||||
getEnvVarWithDefault var def = toS <$>
|
||||
getEnv (toS var) `E.catchIOError` const (return $ toS def)
|
||||
|
||||
baseCfg :: AppConfig
|
||||
baseCfg = let secret = Just $ encodeUtf8 "reallyreallyreallyreallyverysafe" in
|
||||
AppConfig {
|
||||
|
||||
Reference in New Issue
Block a user