@jest/test-result
- Version 29.7.0
- Published
- 15.8 kB
- 4 dependencies
- MIT license
Install
npm i @jest/test-result
yarn add @jest/test-result
pnpm add @jest/test-result
Overview
Overview not available.
Index
Functions
Interfaces
Type Aliases
Functions
function addResult
addResult: (aggregatedResults: AggregatedResult, testResult: TestResult) => void;
function buildFailureTestResult
buildFailureTestResult: ( testPath: string, err: TestResult_2.SerializableError) => TestResult;
function createEmptyTestResult
createEmptyTestResult: () => TestResult;
function formatTestResults
formatTestResults: ( results: AggregatedResult, codeCoverageFormatter?: CodeCoverageFormatter, reporter?: CodeCoverageReporter) => FormattedTestResults;
function makeEmptyAggregatedTestResult
makeEmptyAggregatedTestResult: () => AggregatedResult;
Interfaces
interface RuntimeTransformResult
interface RuntimeTransformResult extends TransformTypes.TransformResult {}
property wrapperLength
wrapperLength: number;
Type Aliases
type AggregatedResult
type AggregatedResult = AggregatedResultWithoutCoverage & { coverageMap?: CoverageMap | null;};
type AssertionLocation
type AssertionLocation = { fullName: string; path: string;};
type AssertionResult
type AssertionResult = TestResult_2.AssertionResult;
type FailedAssertion
type FailedAssertion = { matcherName?: string; message?: string; actual?: unknown; pass?: boolean; passed?: boolean; expected?: unknown; isNot?: boolean; stack?: string; error?: unknown;};
type FormattedTestResults
type FormattedTestResults = { coverageMap?: CoverageMap | null | undefined; numFailedTests: number; numFailedTestSuites: number; numPassedTests: number; numPassedTestSuites: number; numPendingTests: number; numPendingTestSuites: number; numRuntimeErrorTestSuites: number; numTotalTests: number; numTotalTestSuites: number; snapshot: SnapshotSummary; startTime: number; success: boolean; testResults: Array<FormattedTestResult>; wasInterrupted: boolean;};
type SerializableError
type SerializableError = TestResult_2.SerializableError;
type SnapshotSummary
type SnapshotSummary = { added: number; didUpdate: boolean; failure: boolean; filesAdded: number; filesRemoved: number; filesRemovedList: Array<string>; filesUnmatched: number; filesUpdated: number; matched: number; total: number; unchecked: number; uncheckedKeysByFile: Array<UncheckedSnapshot>; unmatched: number; updated: number;};
type Status
type Status = AssertionResult['status'];
type Suite
type Suite = { title: string; suites: Array<Suite>; tests: Array<AssertionResult>;};
type Test
type Test = { context: TestContext; duration?: number; path: string;};
type TestCaseResult
type TestCaseResult = AssertionResult;
type TestContext
type TestContext = { config: Config.ProjectConfig; hasteFS: IHasteFS; moduleMap: IModuleMap; resolver: Resolver;};
type TestEvents
type TestEvents = { 'test-file-start': [Test]; 'test-file-success': [Test, TestResult]; 'test-file-failure': [Test, SerializableError]; 'test-case-start': [string, Circus.TestCaseStartInfo]; 'test-case-result': [string, AssertionResult];};
type TestFileEvent
type TestFileEvent<T extends keyof TestEvents = keyof TestEvents> = ( eventName: T, args: TestEvents[T]) => unknown;
type TestResult
type TestResult = { console?: ConsoleBuffer; coverage?: CoverageMapData; displayName?: Config.DisplayName; failureMessage?: string | null; leaks: boolean; memoryUsage?: number; numFailingTests: number; numPassingTests: number; numPendingTests: number; numTodoTests: number; openHandles: Array<Error>; perfStats: { end: number; runtime: number; slow: boolean; start: number; }; skipped: boolean; snapshot: { added: number; fileDeleted: boolean; matched: number; unchecked: number; uncheckedKeys: Array<string>; unmatched: number; updated: number; }; testExecError?: SerializableError; testFilePath: string; testResults: Array<AssertionResult>; v8Coverage?: V8CoverageResult;};
type TestResultsProcessor
type TestResultsProcessor = ( results: AggregatedResult) => AggregatedResult | Promise<AggregatedResult>;
type V8CoverageResult
type V8CoverageResult = Array<{ codeTransformResult: RuntimeTransformResult | undefined; result: V8Coverage[number];}>;
Package Files (1)
Dependencies (4)
Dev Dependencies (2)
Peer Dependencies (0)
No peer dependencies.
Badge
To add a badge like this oneto your package's README, use the codes available below.
You may also use Shields.io to create a custom badge linking to https://www.jsdocs.io/package/@jest/test-result
.
- Markdown[![jsDocs.io](https://img.shields.io/badge/jsDocs.io-reference-blue)](https://www.jsdocs.io/package/@jest/test-result)
- HTML<a href="https://www.jsdocs.io/package/@jest/test-result"><img src="https://img.shields.io/badge/jsDocs.io-reference-blue" alt="jsDocs.io"></a>
- Updated .
Package analyzed in 1024 ms. - Missing or incorrect documentation? Open an issue for this package.