Header menu logo testify

HintInference Module

Functions and values

Function or value Description

HintInference.dedupePreservingOrder hints

Full Usage: HintInference.dedupePreservingOrder hints

Parameters:
    hints : string list - The candidate hints.

Returns: string list The de-duplicated hints in first-seen order.

Removes duplicate hints while keeping the first occurrence order.

hints : string list

The candidate hints.

Returns: string list

The de-duplicated hints in first-seen order.

HintInference.inferHints report

Full Usage: HintInference.inferHints report

Parameters:
Returns: string list The resolved inferred hints in stable order.

Infers hints from the currently configured hint rules and hint packs.

This uses the active globally configured HintRules and HintPacks.

report : TestifyFailureReport

The failure report to inspect.

Returns: string list

The resolved inferred hints in stable order.

Example

 let hints = HintInference.inferHints report
val hints: obj

HintInference.normalizeHintCandidate hint

Full Usage: HintInference.normalizeHintCandidate hint

Parameters:
    hint : string option - The optional hint candidate.

Returns: string option A cleaned hint or None when the candidate should be ignored.

Normalizes one optional hint candidate by trimming and dropping empty placeholder values.

hint : string option

The optional hint candidate.

Returns: string option

A cleaned hint or None when the candidate should be ignored.

HintInference.normalizeHints hints

Full Usage: HintInference.normalizeHints hints

Parameters:
    hints : string list

Returns: string list
hints : string list
Returns: string list

HintInference.withResolvedHints report

Full Usage: HintInference.withResolvedHints report

Parameters:
Returns: TestifyFailureReport A copy of report whose Hints field contains resolved hints.

Adds normalized explicit and inferred hints back onto a failure report.

report : TestifyFailureReport

The failure report to enrich.

Returns: TestifyFailureReport

A copy of report whose Hints field contains resolved hints.

Type something to start searching.