cypress-xray-plugin
Version:
A Cypress plugin for uploading test results to Xray (test management for Jira)
18 lines (17 loc) • 835 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.ImportExecutionCucumberCommand = void 0;
const command_1 = require("../../../command");
class ImportExecutionCucumberCommand extends command_1.Command {
constructor(parameters, logger, cucumberMultipart) {
super(parameters, logger);
this.cucumberMultipart = cucumberMultipart;
}
async computeResult() {
const results = await this.cucumberMultipart.compute();
const testExecutionIssueKey = await this.parameters.xrayClient.importExecutionCucumberMultipart(results.features, results.info);
await this.parameters.emitter.emit("upload:cucumber", { results, testExecutionIssueKey });
return testExecutionIssueKey;
}
}
exports.ImportExecutionCucumberCommand = ImportExecutionCucumberCommand;