ouroboros-consensus-0.21.0.0: Consensus layer for the Ouroboros blockchain protocol
Safe HaskellSafe-Inferred
LanguageHaskell2010

Test.Util.TestEnv

Description

A tasty command-line option for enabling nightly tests

Synopsis

Documentation

data TestEnv Source #

An Option that indicates the environment in which to run tests.

Constructors

Nightly 
CI 
Dev 

adjustQuickCheckMaxSize ∷ (IntInt) → TestTreeTestTree Source #

Locally adjust the maximum size parameter of QuickCheck tests for the given test subtree, similar to adjustQuickCheckTests.

The size parameter is varied across test runs from 0 to maxSize - 1 cyclically, influencing the result of generators that make use of it, like those that call sized.

The default is 100.

adjustQuickCheckTests ∷ (IntInt) → TestTreeTestTree Source #

Locally adjust the number of QuickCheck tests for the given test subtree. Unless the previous number of tests was exactly '0', the result will always be at least '1'. For instance:

adjustQuickCheckTests (`div` 10)

will reduce the default number of tests by 10.

This matters in particular with tests that take a long time; in that case, we settle for running fewer tests, while still scaling with the different test environments (nightly, ci, dev). This function should almost always be preferred to localOption (QuickCheckTests ...) which sets the number of tests regarless of the test environment.

askTestEnv ∷ (TestEnvTestTree) → TestTree Source #

Query and adjust options for TestEnv

defaultMainWithTestEnv ∷ TestEnvConfig → TestTreeIO () Source #

defaultMain extended with iohkTestEnvIngredient and setting the terminal handles to UTF-8.

defaultTestEnvConfig ∷ TestEnvConfig Source #

Default set of tests for each environment