Skip to content

Commit

Permalink
Merge pull request #179 from D4N14L/fixDisplayName
Browse files Browse the repository at this point in the history
Fix displayName usage in templates
  • Loading branch information
palmerj3 committed Sep 10, 2021
2 parents 6751a86 + e189f2d commit 8e5f72b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion utils/buildJsonResults.js
Expand Up @@ -98,7 +98,9 @@ module.exports = function (report, appDirectory, options) {
const filepath = path.relative(appDirectory, suite.testFilePath);
const filename = path.basename(filepath);
const suiteTitle = suite.testResults[0].ancestorTitles[0];
const displayName = suite.displayName;
const displayName = typeof suite.displayName === 'object'
? suite.displayName.name
: suite.displayName;

// Build replacement map
let suiteNameVariables = {};
Expand Down

0 comments on commit 8e5f72b

Please sign in to comment.