jest-allure2-reporter
Version:
Idiomatic Jest reporter for Allure Framework
22 lines • 988 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.testStep = void 0;
exports.testStep = {
ignored: () => false,
displayName: ({ testStepMetadata }) => testStepMetadata.displayName || testStepMetadata.hookType || 'Untitled step',
start: ({ testStepMetadata }) => testStepMetadata.start,
stop: ({ testStepMetadata }) => testStepMetadata.stop,
stage: ({ testStepMetadata }) => testStepMetadata.stage,
status: ({ testStepMetadata }) => testStepMetadata.status ?? inferStatus(testStepMetadata),
statusDetails: ({ testStepMetadata }) => testStepMetadata.statusDetails ?? {},
attachments: ({ testStepMetadata }) => testStepMetadata.attachments ?? [],
parameters: ({ testStepMetadata }) => testStepMetadata.parameters ?? [],
};
function inferStatus({ stage }) {
return (stage && statuses[stage]) || 'unknown';
}
const statuses = {
finished: 'passed',
interrupted: 'broken',
};
//# sourceMappingURL=testStep.js.map