vt-utils-1.0.0.0: Vector and Text utilities

Safe HaskellNone
LanguageHaskell2010

VtUtils.HUnit

Description

HUnit utilities

Synopsis

Documentation

hunitMain :: Vector Test -> IO () Source #

Runs all, group or one of specified HUnit tests depending on the command line arguments

Example specifying argument to stack test invocation:

stack test --ta "GroupName testName"

If no arguments are specified - all test are run.grlabel

If single argument is specified - it is interpreted as a name of the group.grlabel

If two argument are specified - first one is interpreted as a group name, and second one as a test name

Throws an error on invalid command line argument

Tests results are printed to stdout

Arguments:

  • tests :: Vector Test: HUnit tests to run

hunitRun :: Vector Test -> IO () Source #

Runs all HUnit tests from a specified Vector

Tests results are printed to stdout

Arguments:

  • tests :: Vector Test: HUnit tests to run

hunitRunGroup :: Vector Test -> Text -> IO () Source #

Runs a subset of HUnit tests with a specified label value

Throws an error if no tests in the specified Vector have specified label

Tests results are printed to stdout

Arguments:

  • tests :: Vector Test: HUnit tests
  • label :: Text: Group label

hunitRunSingle :: Vector Test -> Text -> Text -> IO () Source #

Runs a single test from a specified Vector of HUnit tests

Throws an error if a test with a specified group label and test label is not found in specified Vector of tests

Tests results are printed to stdout

Arguments:

  • tests :: Vector Test: HUnit tests
  • grlabel :: Text: Group label
  • tslabel :: Text: Test label