Skip to content

Latest commit

 

History

History
44 lines (25 loc) · 862 Bytes

File metadata and controls

44 lines (25 loc) · 862 Bytes

CTRF


CTRF / findTest

Function: findTest()

findTest(report, criteria): undefined | Test

Defined in: filter.ts:57

Parameters

report

CTRFReport

The CTRF report to search

criteria

FilterCriteria

Filter criteria including id, name, status, tags, etc.

Returns

undefined | Test

The first matching test, or undefined if not found

Example

// Find by ID
const test = findTest(report, { id: 'uuid' });

// Find by name
const test = findTest(report, { name: 'should login' });

// Find by multiple criteria
const test = findTest(report, { status: 'failed', flaky: true });