From 7124cf3346d7c5cfc8a04aa98e15a3c5068dd56d Mon Sep 17 00:00:00 2001 From: isaacs Date: Fri, 10 Jun 2011 11:11:03 -0700 Subject: [PATCH] Test that it doesn't crash when the bindir is missing --- test/packages/npm-test-missing-bindir/package.json | 4 ++++ test/packages/npm-test-missing-bindir/test.js | 5 +++++ 2 files changed, 9 insertions(+) create mode 100644 test/packages/npm-test-missing-bindir/package.json create mode 100644 test/packages/npm-test-missing-bindir/test.js diff --git a/test/packages/npm-test-missing-bindir/package.json b/test/packages/npm-test-missing-bindir/package.json new file mode 100644 index 0000000000000..49e26742df58f --- /dev/null +++ b/test/packages/npm-test-missing-bindir/package.json @@ -0,0 +1,4 @@ +{ "name":"npm-test-missing-bindir" +, "version" : "0.0.0" +, "scripts" : { "test" : "node test.js" } +, "directories": { "bin" : "./not-found" } } diff --git a/test/packages/npm-test-missing-bindir/test.js b/test/packages/npm-test-missing-bindir/test.js new file mode 100644 index 0000000000000..f548458ac042c --- /dev/null +++ b/test/packages/npm-test-missing-bindir/test.js @@ -0,0 +1,5 @@ + +var assert = require("assert") +assert.equal(undefined, process.env.npm_config__password, "password exposed!") +assert.equal(undefined, process.env.npm_config__auth, "auth exposed!") +assert.equal(undefined, process.env.npm_config__authCrypt, "authCrypt exposed!")