diff --git a/lib/reporters/junit/index.js b/lib/reporters/junit/index.js index dc090a35d..3fe609864 100644 --- a/lib/reporters/junit/index.js +++ b/lib/reporters/junit/index.js @@ -13,6 +13,14 @@ var _ = require('lodash'), * @returns {*} */ JunitReporter = function (newman, reporterOptions) { + /** + * Convert the response entries to JSON format. + * @param {Array} errors + * @returns {Array} + */ + function xml(errors) { + return errors.map(error => JSON.stringify(error)); + } newman.on('beforeDone', function () { var report = _.get(newman, 'summary.run.executions'), collection = _.get(newman, 'summary.collection'),