Skip to content
This repository has been archived by the owner on Aug 11, 2022. It is now read-only.

Commit

Permalink
test: Default audit to off when testing
Browse files Browse the repository at this point in the history
PR-URL: #20389
Credit: @iarna
Reviewed-By: @zkat
  • Loading branch information
iarna authored and zkat committed Apr 20, 2018
1 parent 8e71334 commit 09c7348
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions test/common-tap.js
Expand Up @@ -17,11 +17,14 @@ if (!global.setImmediate || !require('timers').setImmediate) {
var spawn = require('child_process').spawn
var path = require('path')


var port = exports.port = 1337
exports.registry = 'http://localhost:' + port
const ourenv = {}
ourenv.npm_config_loglevel = 'error'
ourenv.npm_config_progress = 'false'
ourenv.npm_config_metrics = 'false'
ourenv.npm_config_audit = 'false'

var npm_config_cache = path.resolve(__dirname, 'npm_cache')
ourenv.npm_config_cache = exports.npm_config_cache = npm_config_cache
Expand Down Expand Up @@ -63,6 +66,9 @@ exports.npm = function (cmd, opts, cb) {
if (!opts.env.npm_config_send_metrics) {
opts.env.npm_config_send_metrics = 'false'
}
if (!opts.env.npm_config_audit) {
opts.env.npm_config_audit = 'false'
}

nodeBin = opts.nodeExecPath || nodeBin

Expand Down

0 comments on commit 09c7348

Please sign in to comment.