Types and functions to manipulate a test result.
Type summarizing the results of a test run. It is obtained from the list of expectations returned by calling runner.run ().
fromExpectations : List String -> List Expectation -> TestResult
Convert a list of expectations (results of a run) into a TestResult
.
Return the Failed
variant if there is any todo or failure in the expectations.
setDuration : Basics.Float -> TestResult -> TestResult
Set the duration that the test took.
setLogs : List String -> TestResult -> TestResult
Set the logs received for that test.
encode : TestResult -> Json.Decode.Value
Encode a TestResult
.
decoder : Json.Decode.Decoder TestResult
Decode a TestResult
.
{ totalDuration : Basics.Float
, passedCount : Basics.Int
, failedCount : Basics.Int
, todoCount : Basics.Int
}
Quantitative summary of all test results.
summary : Array TestResult -> Summary
Report a quantitative summary of test results.