Safe Haskell | None |
---|---|
Language | Haskell2010 |
Top-level module that re-exports functionality from sub-modules.
Modules that only define unit tests and quickcheck properties typically
only need to import this module.
Your test driver should additionally import TestManager
and,
if needed, BlackBoxTest
.
- module Test.Framework.HUnitWrapper
- makeUnitTest :: AssertionWithTestOptions a => TestID -> Location -> a -> Test
- module Test.Framework.QuickCheckWrapper
- makeQuickCheckTest :: TestID -> Location -> Assertion -> Test
- module Test.Framework.AssertM
- makeTestSuite :: TestID -> [Test] -> TestSuite
- data TestSuite
- htfMain :: TestableHTF t => t -> IO ()
- htfMainWithArgs :: TestableHTF t => [String] -> t -> IO ()
- makeLoc :: String -> Int -> Location
Unit tests
module Test.Framework.HUnitWrapper
makeUnitTest :: AssertionWithTestOptions a => TestID -> Location -> a -> Test Source
Construct a unit test from the given IO
action.
Mainly used internally by the htfpp preprocessor.
Quickcheck
makeQuickCheckTest :: TestID -> Location -> Assertion -> Test Source
Construct a test where the given Assertion
checks a quick check property.
Mainly used internally by the htfpp preprocessor.
Generic assertions
module Test.Framework.AssertM
Organizing tests
makeTestSuite :: TestID -> [Test] -> TestSuite Source
htfMain :: TestableHTF t => t -> IO () Source
Runs something testable by parsing the commandline arguments as test options
(using parseTestArgs
). Exits with the exit code returned by runTestWithArgs
.
This function is the main entry point for running tests.
htfMainWithArgs :: TestableHTF t => [String] -> t -> IO () Source
Runs something testable by parsing the commandline arguments as test options
(using parseTestArgs
). Exits with the exit code returned by runTestWithArgs
.