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

jest-summarizing-reporter

Package Overview
Dependencies
Maintainers
1
Versions
12
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

jest-summarizing-reporter - npm Package Compare versions

Comparing version 1.1.2 to 1.1.3

test/fake_suites/__snapshots__/FakeSnapshotSuite_1.test.js.snap

2

package.json
{
"name": "jest-summarizing-reporter",
"version": "1.1.2",
"version": "1.1.3",
"description": "Custom reporter for jest, that only prints test result summary.",

@@ -5,0 +5,0 @@ "main": "./src/JestSummaryReporter.js",

@@ -14,2 +14,3 @@ const { red, green, black, bgLightGreen, bgLightRed, lightRed, lightYellow, white, yellow } = require('./utils/BashColorUtils');

onRunComplete(contexts, results) {
const { snapshot } = results;
println(2);

@@ -25,2 +26,5 @@

printFailedSuites(results);
if (snapshot.failure) {
printUncheckedSnapshotsSummary(snapshot);
}
printSummary(results);

@@ -61,6 +65,7 @@ }

numPassedTests: passedTests,
numFailedTests: failedTests
numFailedTests: failedTests,
success
} = results;
let failedSuites = totalSuites - passedSuites - pendingSuites;
let failed = failedSuites > 0;
let failed = !success;

@@ -115,3 +120,14 @@ print('Summary:');

function printUncheckedSnapshotsSummary(snapshot) {
print(`${bgLightRed(black(" UNUSED SNAPSHOTS "))} found. 'npm t -- -u' to remove them`);
snapshot.uncheckedKeysByFile
.forEach(printAsFailure);
println(2);
function printAsFailure(file) {
let path = processFullPath(file.filePath);
print(`${path.path}${white(path.file)}`);
}
}
function suiteFailed(suite) {

@@ -118,0 +134,0 @@ return suite.numFailingTests > 0 || suite.failureMessage;

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