mocha-github-actions-reporter
Advanced tools
Comparing version 0.3.0 to 0.3.1
18
index.js
const core = require('@actions/core'); | ||
const { SUMMARY_ENV_VAR } = require('@actions/core/lib/summary'); | ||
const { issueCommand } = require('@actions/core/lib/command'); | ||
@@ -39,10 +40,13 @@ const mocha = require('mocha'); | ||
} | ||
core.summary.addRaw(`:white_check_mark: ${this.stats.passes || 0} passing (${milliseconds(this.stats.duration)})`, true); | ||
if (this.stats.pending) { | ||
core.summary.addRaw(`:pause_button: ${this.stats.pending} pending`, true); | ||
// Check if Job Summary is supported on this platform | ||
if (process.env[SUMMARY_ENV_VAR]) { | ||
core.summary.addRaw(`:white_check_mark: ${this.stats.passes || 0} passing (${milliseconds(this.stats.duration)})`, true); | ||
if (this.stats.pending) { | ||
core.summary.addRaw(`:pause_button: ${this.stats.pending} pending`, true); | ||
} | ||
if (this.stats.failures) { | ||
core.summary.addRaw(`:x: ${this.stats.failures} failing`, true); | ||
} | ||
core.summary.write(); | ||
} | ||
if (this.stats.failures) { | ||
core.summary.addRaw(`:x: ${this.stats.failures} failing`, true); | ||
} | ||
core.summary.write(); | ||
}); | ||
@@ -49,0 +53,0 @@ } |
{ | ||
"name": "mocha-github-actions-reporter", | ||
"version": "0.3.0", | ||
"version": "0.3.1", | ||
"description": "Reporter for mocha that outputs Github Actions annotations", | ||
@@ -5,0 +5,0 @@ "main": "index.js", |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
Environment variable access
Supply chain riskPackage accesses environment variables, which may be a sign of credential stuffing or data theft.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
4395
61
2