Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

jest-junit

Package Overview
Dependencies
Maintainers
1
Versions
52
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jest-junit - npm Package Compare versions

Comparing version 3.7.0 to 4.0.0

2

package.json
{
"name": "jest-junit",
"version": "3.7.0",
"version": "4.0.0",
"description": "A jest result processor that generates junit xml files",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -16,2 +16,6 @@ 'use strict';

const executionTime = function (startTime, endTime) {
return (endTime - startTime) / 1000;
}
module.exports = function (report, appDirectory, options) {

@@ -26,3 +30,6 @@ // Generate a single XML file for all jest tests

'failures': 0,
'time': 0
// Overall execution time:
// Since tests are typically executed in parallel this time can be significantly smaller
// than the sum of the individual test suites
'time': executionTime(report.startTime, Date.now())
}

@@ -64,3 +71,3 @@ }

const suiteNumTests = suite.numFailingTests + suite.numPassingTests + suite.numPendingTests;
const suiteExecutionTime = (suite.perfStats.end - suite.perfStats.start) / 1000;
const suiteExecutionTime = executionTime(suite.perfStats.start, suite.perfStats.end);

@@ -84,3 +91,2 @@ let testSuite = {

jsonResults.testsuites[0]._attr.tests += suiteNumTests;
jsonResults.testsuites[0]._attr.time += suiteExecutionTime;

@@ -87,0 +93,0 @@ // Iterate through test cases

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc