doctest-parallel-0.4: Test interactive Haskell examples

Safe Haskell | None
Language | Haskell2010

Test.DocTest

Contents

- Internal

Synopsis

- mainFromCabal :: String -> [String] -> IO ()
- mainFromLibrary :: Library -> [String] -> IO ()
- mainFromCabalWithConfig :: String -> Config -> IO ()
- mainFromLibraryWithConfig :: Library -> Config -> IO ()
- filterModules :: [ModuleName] -> [ModuleName] -> [ModuleName]
- isSuccess :: Summary -> Bool
- setSeed :: (?verbosity :: LogLevel) => ModuleConfig -> IO ModuleConfig
- run :: Library -> Config -> IO Summary

# Documentation

mainFromCabal :: String -> [String] -> IO () Source #

Run doctest with given list of arguments.

Example:

    mainFromCabal "my-project" =<< getArgs

mainFromLibrary :: Library -> [String] -> IO () Source #

Like `mainFromCabal`, but with a given library.

mainFromCabalWithConfig :: String -> Config -> IO () Source #

Run doctest given config.

Example:

    mainFromCabal "my-project" defaultConfig

mainFromLibraryWithConfig :: Library -> Config -> IO () Source #

Run doctests with given library and config.

# Internal

filterModules :: [ModuleName] -> [ModuleName] -> [ModuleName] Source #

Filter modules to be tested against a list of modules to be tested (specified by the user on the command line). If list is empty, test all modules. Throws and error if a non-existing module was specified.

isSuccess :: Summary -> Bool Source #

setSeed :: (?verbosity :: LogLevel) => ModuleConfig -> IO ModuleConfig Source #

run :: Library -> Config -> IO Summary Source #

Run doctest for given library and config. Produce a summary of all tests.