ghc-mod/test/doctests.hs

24 lines
795 B
Haskell
Raw Normal View History

2015-03-05 15:50:06 +00:00
{-# LANGUAGE CPP #-}
2013-09-20 12:10:31 +00:00
module Main where
import Test.DocTest
import System.Environment
import Data.Maybe
2013-09-20 12:10:31 +00:00
main :: IO ()
main = do
distdir <- (fromMaybe "dist" . lookup "DOCTEST_DIST_DIR") `fmap` getEnvironment
doctest
[ "-package", "ghc-" ++ VERSION_ghc
, "-package", "transformers-" ++ VERSION_transformers
, "-package", "mtl-" ++ VERSION_mtl
, "-package", "directory-" ++ VERSION_directory
, "-XScopedTypeVariables", "-XRecordWildCards", "-XNamedFieldPuns", "-XConstraintKinds", "-XFlexibleContexts", "-XDataKinds", "-XKindSignatures", "-XTypeOperators", "-XViewPatterns"
, "-i" ++ distdir ++ "/build/autogen/"
, "-icore/"
2017-05-18 00:40:21 +00:00
, "-ishared"
-- , "-optP-include"
-- , "-optP" ++ distdir ++ "/build/autogen/cabal_macros.h"
, "GhcMod.hs"
]