allure-playwright 3.13.0 → 3.15.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -34,7 +34,7 @@ npm install -D allure-playwright
34
34
 
35
35
  Install Allure Report separately when you want to render the generated `allure-results`:
36
36
 
37
- - follow the [Allure Report 2 installation guide](https://allurereport.org/docs/install/) to use the `allure` CLI
37
+ - follow the [Allure Report 2 installation guide](https://allurereport.org/docs/v2/install/) to use the `allure` CLI
38
38
  - or install Allure Report 3 with `npm install -D allure` to use `npx allure`
39
39
 
40
40
  ## Supported versions and platforms
@@ -77,6 +77,32 @@ directory.
77
77
 
78
78
  You may select another location, or further customize the reporter's behavior with [the configuration options](https://allurereport.org/docs/playwright-configuration/).
79
79
 
80
+ To hide steps generated from Playwright annotations that are not mapped to Allure metadata, set
81
+ `reportAnnotations: false`:
82
+
83
+ ```js
84
+ export default defineConfig({
85
+ reporter: [["allure-playwright", { reportAnnotations: false }]],
86
+ });
87
+ ```
88
+
89
+ Annotation steps are enabled by default, independently of `detail`. This option only controls their
90
+ presentation as steps: labels, links, descriptions, and skip/fixme handling are preserved. The original
91
+ annotations remain available to Playwright and other reporters.
92
+
93
+ To hide Playwright API calls while keeping `expect` assertions as steps, set `reportMatchers: true`
94
+ with `detail: false`:
95
+
96
+ ```js
97
+ export default defineConfig({
98
+ reporter: [["allure-playwright", { detail: false, reportMatchers: true }]],
99
+ });
100
+ ```
101
+
102
+ `reportMatchers` controls Playwright `expect` steps, including assertions in hooks. When omitted,
103
+ it follows `detail` (`true` by default). Set `reportMatchers: false` to hide assertion steps while
104
+ keeping other details enabled. User-created steps and attachments are reported independently.
105
+
80
106
  To use name-based test selectors instead of source locations, enable the legacy full name format:
81
107
 
82
108
  ```js
package/dist/cjs/index.js CHANGED
@@ -83,6 +83,8 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
83
83
  _defineProperty(this, "testFullNames", new WeakMap());
84
84
  _defineProperty(this, "emittedHookGlobalErrorKeys", new Set());
85
85
  _defineProperty(this, "testPlan", (0, _reporter.parseTestPlan)());
86
+ _defineProperty(this, "replayedBlobCount", 0);
87
+ _defineProperty(this, "activeBlobIndex", void 0);
86
88
  this.options = _objectSpread({
87
89
  suiteTitle: true,
88
90
  detail: true
@@ -197,8 +199,20 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
197
199
  key: "onConfigure",
198
200
  value: function onConfigure(config) {
199
201
  this.config = config;
200
- this.outputDir = config.projects[0].outputDir;
201
- this.snapshotDir = config.projects[0].snapshotDir;
202
+ this.replayedBlobCount = 0;
203
+ this.activeBlobIndex = undefined;
204
+ }
205
+
206
+ // Playwright's v2 merge dispatcher brackets each blob with these callbacks.
207
+ }, {
208
+ key: "onReportConfigure",
209
+ value: function onReportConfigure() {
210
+ this.activeBlobIndex = ++this.replayedBlobCount;
211
+ }
212
+ }, {
213
+ key: "onReportEnd",
214
+ value: function onReportEnd() {
215
+ this.activeBlobIndex = undefined;
202
216
  }
203
217
  }, {
204
218
  key: "onError",
@@ -215,7 +229,10 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
215
229
  }, {
216
230
  key: "onBegin",
217
231
  value: function onBegin(suite) {
232
+ var _this$config$projects, _this$config$projects2;
218
233
  this.suite = suite;
234
+ this.outputDir = (_this$config$projects = this.config.projects[0]) === null || _this$config$projects === void 0 ? void 0 : _this$config$projects.outputDir;
235
+ this.snapshotDir = (_this$config$projects2 = this.config.projects[0]) === null || _this$config$projects2 === void 0 ? void 0 : _this$config$projects2.snapshotDir;
219
236
  this.emittedHookGlobalErrorKeys.clear();
220
237
  this.allureRuntime = new _reporter.ReporterRuntime(_objectSpread(_objectSpread({}, this.options), {}, {
221
238
  writer: (0, _reporter.createDefaultWriter)({
@@ -225,12 +242,13 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
225
242
  }
226
243
  }, {
227
244
  key: "onTestBegin",
228
- value: function onTestBegin(test) {
245
+ value: function onTestBegin(test, testResult) {
229
246
  var _metadata$relativeFil, _metadata$project, _metadata$project2;
230
247
  var metadata = this.getStaticTestMetadata(test);
231
248
  var titlePath = metadata.projectName ? [metadata.projectName].concat(_toConsumableArray(metadata.relativeFileParts), _toConsumableArray(metadata.suiteTitles)) : (_metadata$relativeFil = metadata.relativeFileParts).concat.apply(_metadata$relativeFil, _toConsumableArray(metadata.suiteTitles));
232
249
  var result = {
233
250
  name: metadata.titleMetadata.cleanTitle,
251
+ start: testResult.startTime.getTime(),
234
252
  labels: [].concat(_toConsumableArray(metadata.titleMetadata.labels), _toConsumableArray((0, _reporter.getEnvironmentLabels)())),
235
253
  links: _toConsumableArray(metadata.titleMetadata.links),
236
254
  parameters: [],
@@ -293,6 +311,9 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
293
311
  result.labels.push(annotationLabel);
294
312
  continue;
295
313
  }
314
+ if (this.options.reportAnnotations === false) {
315
+ continue;
316
+ }
296
317
  result.steps.push({
297
318
  name: "".concat(annotation.type, ": ").concat(annotation.description),
298
319
  status: _allureJsCommons.Status.PASSED,
@@ -581,7 +602,7 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
581
602
  }, {
582
603
  key: "onStepBegin",
583
604
  value: function onStepBegin(test, _result, step) {
584
- var _this$pwStepUuid$get2;
605
+ var _assertClassBrand$cal;
585
606
  var testUuid = this.allureResultsUuids.get(test.id);
586
607
  if (!testUuid) {
587
608
  // eslint-disable-next-line no-console
@@ -604,11 +625,9 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
604
625
  uuid: (0, _reporter.randomUuid)()
605
626
  });
606
627
  if (["test.attach", "attach"].includes(step.category) && !isHookStep) {
607
- var _this$pwStepUuid$get;
608
- var parent = step.parent ? (_this$pwStepUuid$get = this.pwStepUuid.get(step.parent)) !== null && _this$pwStepUuid$get !== void 0 ? _this$pwStepUuid$get : null : null;
609
628
  this.attachmentTargetByStep.set(step, {
610
629
  name: (0, _utils.normalizeAttachStepTitle)(step.title),
611
- stepUuid: parent !== null && parent !== void 0 ? parent : undefined
630
+ stepUuid: _assertClassBrand(_AllureReporter_brand, this, _getReportedParentUuid).call(this, step)
612
631
  });
613
632
  return;
614
633
  }
@@ -650,7 +669,7 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
650
669
  }
651
670
  return;
652
671
  }
653
- var parentUuid = step.parent ? (_this$pwStepUuid$get2 = this.pwStepUuid.get(step.parent)) !== null && _this$pwStepUuid$get2 !== void 0 ? _this$pwStepUuid$get2 : null : null;
672
+ var parentUuid = (_assertClassBrand$cal = _assertClassBrand(_AllureReporter_brand, this, _getReportedParentUuid).call(this, step)) !== null && _assertClassBrand$cal !== void 0 ? _assertClassBrand$cal : null;
654
673
  var createdUuid = this.allureRuntime.startStep(testUuid, parentUuid, baseStep);
655
674
  if (createdUuid) {
656
675
  this.pwStepUuid.set(step, createdUuid);
@@ -736,7 +755,7 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
736
755
  var _onTestEnd = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee3(test, result) {
737
756
  var _this2 = this,
738
757
  _this$attachmentTarge2;
739
- var testUuid, threadId, thread, error, _test$parent$titlePat, _test$parent$titlePat2, projectSuiteTitle, fileSuiteTitle, suiteTitles, beforeHooksStack, afterHooksStack, targets, targetsByName, _iterator7, _step7, _targetsByName$get, t, q, takeByName, _iterator8, _step8, attachment, isRuntimeMessage, stepInfo, _stepInfo$hookStep$uu2, _stepInfo$hookStep2, message, targetStack, _targetStack, stepUuid, _targetStack2, stepResult, fileName, _t3;
758
+ var testUuid, threadId, blob, thread, _test$parent$titlePat, _test$parent$titlePat2, projectSuiteTitle, fileSuiteTitle, suiteTitles, beforeHooksStack, afterHooksStack, targets, targetsByName, _iterator7, _step7, _targetsByName$get, t, q, takeByName, _iterator8, _step8, attachment, isRuntimeMessage, stepInfo, _stepInfo$hookStep$uu2, _stepInfo$hookStep2, message, targetStack, _targetStack, stepUuid, _targetStack2, stepResult, fileName, _t3;
740
759
  return _regenerator().w(function (_context3) {
741
760
  while (1) switch (_context3.n) {
742
761
  case 0:
@@ -751,8 +770,8 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
751
770
  case 1:
752
771
  // We need to check parallelIndex first because pw introduced this field only in v1.30.0
753
772
  threadId = result.parallelIndex !== undefined ? result.parallelIndex : result.workerIndex;
754
- thread = "pid-".concat(_nodeProcess["default"].pid, "-worker-").concat(threadId);
755
- error = result.error; // only apply default suites if not set by user
773
+ blob = this.activeBlobIndex === undefined ? "" : "-blob-".concat(this.activeBlobIndex);
774
+ thread = "pid-".concat(_nodeProcess["default"].pid).concat(blob, "-worker-").concat(threadId); // only apply default suites if not set by user
756
775
  _test$parent$titlePat = test.parent.titlePath(), _test$parent$titlePat2 = _toArray(_test$parent$titlePat), projectSuiteTitle = _test$parent$titlePat2[1], fileSuiteTitle = _test$parent$titlePat2[2], suiteTitles = _test$parent$titlePat2.slice(3);
757
776
  beforeHooksStack = this.beforeHooksStepsStack.get(test.id);
758
777
  afterHooksStack = this.afterHooksStepsStack.get(test.id);
@@ -777,8 +796,20 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
777
796
  value: suiteTitles.join(" > ")
778
797
  });
779
798
  }
780
- if (error) {
781
- testResult.statusDetails = _objectSpread({}, (0, _sdk.getMessageAndTraceFromError)(error));
799
+ if (result.errors.length > 0) {
800
+ var details = result.errors.map(function (error) {
801
+ return (0, _utils.getStatusDetails)(error);
802
+ });
803
+ testResult.statusDetails = _objectSpread(_objectSpread({}, details[0]), {}, {
804
+ message: details.map(function (_ref3) {
805
+ var message = _ref3.message;
806
+ return message;
807
+ }).filter(Boolean).join("\n\n") || undefined,
808
+ trace: details.map(function (_ref4) {
809
+ var trace = _ref4.trace;
810
+ return trace;
811
+ }).filter(Boolean).join("\n\n") || undefined
812
+ });
782
813
  } else {
783
814
  var _test$annotations;
784
815
  var skipReason = (_test$annotations = test.annotations) === null || _test$annotations === void 0 || (_test$annotations = _test$annotations.find(function (annotation) {
@@ -955,7 +986,7 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
955
986
  testResult.labels = newLabels;
956
987
  });
957
988
  this.allureRuntime.stopTest(testUuid, {
958
- duration: result.duration
989
+ stop: result.startTime.getTime() + result.duration
959
990
  });
960
991
  this.allureRuntime.writeTest(testUuid);
961
992
  this.attachmentTargets["delete"](test.id);
@@ -974,23 +1005,27 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
974
1005
  key: "emitGlobalErrorFromHookStep",
975
1006
  value: function emitGlobalErrorFromHookStep(step) {
976
1007
  var _details$message, _details$trace;
977
- if (!step.error || !isGlobalErrorHookStep(step)) {
1008
+ if (!step.error || !isGlobalErrorHookStep(step) || (0, _utils.getSkipModifierError)(step.error)) {
978
1009
  return;
979
1010
  }
980
- var details = (0, _sdk.getMessageAndTraceFromError)(step.error);
1011
+ var details = (0, _utils.getStatusDetails)(step.error);
981
1012
  var key = [step.title, step.startTime.getTime(), (_details$message = details.message) !== null && _details$message !== void 0 ? _details$message : "", (_details$trace = details.trace) !== null && _details$trace !== void 0 ? _details$trace : ""].join("\0");
982
1013
  if (this.emittedHookGlobalErrorKeys.has(key)) {
983
1014
  return;
984
1015
  }
985
1016
  this.emittedHookGlobalErrorKeys.add(key);
986
- this.allureRuntime.applyGlobalRuntimeMessages([toGlobalErrorMessage((0, _utils.normalizeHookTitle)(step.title), details)]);
1017
+ this.allureRuntime.applyGlobalRuntimeMessages([(0, _sdk.toGlobalErrorMessage)({
1018
+ name: (0, _utils.normalizeHookTitle)(step.title),
1019
+ details: details,
1020
+ status: (0, _sdk.getStatusFromError)(step.error)
1021
+ })]);
987
1022
  }
988
1023
  }, {
989
1024
  key: "addSkippedResults",
990
1025
  value: function () {
991
1026
  var _addSkippedResults = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee4() {
992
1027
  var _this3 = this;
993
- var unprocessedCases, _iterator9, _step9, testCase, _t4;
1028
+ var unprocessedCases, _iterator9, _step9, testCase, result, _t4;
994
1029
  return _regenerator().w(function (_context4) {
995
1030
  while (1) switch (_context4.n) {
996
1031
  case 0:
@@ -1008,9 +1043,7 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
1008
1043
  break;
1009
1044
  }
1010
1045
  testCase = _step9.value;
1011
- this.onTestBegin(testCase);
1012
- _context4.n = 3;
1013
- return this.onTestEnd(testCase, {
1046
+ result = {
1014
1047
  status: _allureJsCommons.Status.SKIPPED,
1015
1048
  attachments: [],
1016
1049
  duration: 0,
@@ -1023,7 +1056,10 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
1023
1056
  stdout: [],
1024
1057
  startTime: this.globalStartTime,
1025
1058
  annotations: []
1026
- });
1059
+ };
1060
+ this.onTestBegin(testCase, result);
1061
+ _context4.n = 3;
1062
+ return this.onTestEnd(testCase, result);
1027
1063
  case 3:
1028
1064
  _context4.n = 2;
1029
1065
  break;
@@ -1118,11 +1154,11 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
1118
1154
  }, {
1119
1155
  key: "getStaticTestMetadata",
1120
1156
  value: function getStaticTestMetadata(test) {
1121
- var _ref3, _test$parent$project, _titleMetadata$labels;
1157
+ var _ref5, _test$parent$project, _titleMetadata$labels;
1122
1158
  var titleMetadata = (0, _sdk.extractMetadataFromString)(test.title);
1123
- var project = (_ref3 = (_test$parent$project = test.parent.project()) !== null && _test$parent$project !== void 0 ? _test$parent$project : this.config.projects.find(function (candidate) {
1159
+ var project = (_ref5 = (_test$parent$project = test.parent.project()) !== null && _test$parent$project !== void 0 ? _test$parent$project : this.config.projects.find(function (candidate) {
1124
1160
  return test.location.file === candidate.testDir || test.location.file.startsWith("".concat(candidate.testDir).concat(_nodePath["default"].sep));
1125
- })) !== null && _ref3 !== void 0 ? _ref3 : this.config.projects[0];
1161
+ })) !== null && _ref5 !== void 0 ? _ref5 : this.config.projects[0];
1126
1162
  var testFilePath = _nodePath["default"].relative(project.testDir, test.location.file);
1127
1163
  var relativeFileParts = testFilePath.split(_nodePath["default"].sep);
1128
1164
  var relativeFile = relativeFileParts.join("/");
@@ -1234,8 +1270,8 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
1234
1270
  key: "processAttachment",
1235
1271
  value: function () {
1236
1272
  var _processAttachment = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee8(testUuid, attachmentStepUuid, attachment) {
1237
- var _replace;
1238
- var allureRuntimeMessage, message, parentUuid, contentType, pathWithoutEndFromSnapshotDir, pathWithoutEnd, fileExists, readImageFromDirs, actualBase64, expectedBase64, diffBase64, diffName;
1273
+ var _attachment$path$matc, _attachment$path, _replace;
1274
+ var allureRuntimeMessage, message, parentUuid, contentType, extMatch, ext, pathWithoutEndFromSnapshotDir, pathWithoutEnd, fileExists, readImageFromDirs, actualBase64, expectedBase64, diffBase64, diffName;
1239
1275
  return _regenerator().w(function (_context8) {
1240
1276
  while (1) switch (_context8.n) {
1241
1277
  case 0:
@@ -1295,8 +1331,10 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
1295
1331
  }
1296
1332
  return _context8.a(2);
1297
1333
  case 7:
1298
- pathWithoutEndFromSnapshotDir = (_replace = attachment.path.replace(this.outputDir, this.snapshotDir)) === null || _replace === void 0 ? void 0 : _replace.replace(_utils.diffEndRegexp, "").replace(/\.png/, "");
1299
- pathWithoutEnd = attachment.path.replace(_utils.diffEndRegexp, "").replace(/\.png/, "");
1334
+ extMatch = (_attachment$path$matc = (_attachment$path = attachment.path) === null || _attachment$path === void 0 ? void 0 : _attachment$path.match(/\.(png|webp)$/)) !== null && _attachment$path$matc !== void 0 ? _attachment$path$matc : attachment.name.match(/\.(png|webp)$/);
1335
+ ext = extMatch ? extMatch[0] : ".png";
1336
+ pathWithoutEndFromSnapshotDir = (_replace = attachment.path.replace(this.outputDir, this.snapshotDir)) === null || _replace === void 0 ? void 0 : _replace.replace(_utils.diffEndRegexp, "").replace(/\.(png|webp)$/, "");
1337
+ pathWithoutEnd = attachment.path.replace(_utils.diffEndRegexp, "").replace(/\.(png|webp)$/, "");
1300
1338
  if (!(this.processedDiffs.includes(pathWithoutEnd) || this.processedDiffs.includes(pathWithoutEndFromSnapshotDir))) {
1301
1339
  _context8.n = 8;
1302
1340
  break;
@@ -1304,7 +1342,7 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
1304
1342
  return _context8.a(2);
1305
1343
  case 8:
1306
1344
  fileExists = /*#__PURE__*/function () {
1307
- var _ref4 = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee6(filePath) {
1345
+ var _ref6 = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee6(filePath) {
1308
1346
  return _regenerator().w(function (_context6) {
1309
1347
  while (1) switch (_context6.n) {
1310
1348
  case 0:
@@ -1320,17 +1358,17 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
1320
1358
  }, _callee6);
1321
1359
  }));
1322
1360
  return function fileExists(_x8) {
1323
- return _ref4.apply(this, arguments);
1361
+ return _ref6.apply(this, arguments);
1324
1362
  };
1325
1363
  }();
1326
1364
  readImageFromDirs = /*#__PURE__*/function () {
1327
- var _ref5 = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee7(modifier) {
1365
+ var _ref7 = _asyncToGenerator(/*#__PURE__*/_regenerator().m(function _callee7(modifier) {
1328
1366
  var defaultPath, snapshotPath;
1329
1367
  return _regenerator().w(function (_context7) {
1330
1368
  while (1) switch (_context7.n) {
1331
1369
  case 0:
1332
- defaultPath = "".concat(pathWithoutEnd, "-").concat(modifier, ".png");
1333
- snapshotPath = "".concat(pathWithoutEndFromSnapshotDir, "-").concat(modifier, ".png");
1370
+ defaultPath = "".concat(pathWithoutEnd, "-").concat(modifier).concat(ext);
1371
+ snapshotPath = "".concat(pathWithoutEndFromSnapshotDir, "-").concat(modifier).concat(ext);
1334
1372
  _context7.n = 1;
1335
1373
  return fileExists(defaultPath);
1336
1374
  case 1:
@@ -1360,7 +1398,7 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
1360
1398
  }, _callee7);
1361
1399
  }));
1362
1400
  return function readImageFromDirs(_x9) {
1363
- return _ref5.apply(this, arguments);
1401
+ return _ref7.apply(this, arguments);
1364
1402
  };
1365
1403
  }();
1366
1404
  _context8.n = 9;
@@ -1407,7 +1445,9 @@ var AllureReporter = exports.AllureReporter = /*#__PURE__*/function () {
1407
1445
  * @deprecated for removal, import functions directly from "allure-js-commons".
1408
1446
  */
1409
1447
  function _shouldIgnoreStep(step) {
1410
- if (!this.options.detail && !["test.step", "attach", "test.attach"].includes(step.category)) {
1448
+ var _this$options$reportM;
1449
+ var detail = step.category === "expect" ? (_this$options$reportM = this.options.reportMatchers) !== null && _this$options$reportM !== void 0 ? _this$options$reportM : this.options.detail : this.options.detail;
1450
+ if (!detail && !["test.step", "attach", "test.attach"].includes(step.category)) {
1411
1451
  return true;
1412
1452
  }
1413
1453
 
@@ -1422,6 +1462,14 @@ function _shouldIgnoreStep(step) {
1422
1462
  }
1423
1463
  return false;
1424
1464
  }
1465
+ function _getReportedParentUuid(step) {
1466
+ for (var parent = step.parent; parent; parent = parent.parent) {
1467
+ var uuid = this.pwStepUuid.get(parent);
1468
+ if (uuid !== undefined) {
1469
+ return uuid;
1470
+ }
1471
+ }
1472
+ }
1425
1473
  function _getOrCreateHookStack(testId, isBeforeHook, startTime) {
1426
1474
  var map = isBeforeHook ? this.beforeHooksStepsStack : this.afterHooksStepsStack;
1427
1475
  var stack = map.get(testId);
@@ -1444,14 +1492,6 @@ var allure = exports.allure = _legacy.allurePlaywrightLegacyApi;
1444
1492
  * @deprecated for removal, import functions directly from "@playwright/test".
1445
1493
  */
1446
1494
 
1447
- var toGlobalErrorMessage = function toGlobalErrorMessage(name, details) {
1448
- return {
1449
- type: "global_error",
1450
- data: _objectSpread(_objectSpread({}, details), {}, {
1451
- message: details.message ? "".concat(name, " failed: ").concat(details.message) : "".concat(name, " failed")
1452
- })
1453
- };
1454
- };
1455
1495
  var isDirectHookStep = function isDirectHookStep(step) {
1456
1496
  var _step$parent, _step$parent2;
1457
1497
  return (((_step$parent = step.parent) === null || _step$parent === void 0 ? void 0 : _step$parent.title) === _utils.BEFORE_HOOKS_ROOT_STEP_TITLE || ((_step$parent2 = step.parent) === null || _step$parent2 === void 0 ? void 0 : _step$parent2.title) === _utils.AFTER_HOOKS_ROOT_STEP_TITLE) && step.category === "hook";