Skip to content

Commit

Permalink
Don't do the publishTest
Browse files Browse the repository at this point in the history
These need to be done in a better way, with a local standalone
couchdb.

See the tests for the 'npm/npmjs.org' repo for how to spin this up.
  • Loading branch information
isaacs committed Feb 13, 2014
1 parent a52ec56 commit 8066571
Showing 1 changed file with 0 additions and 35 deletions.
35 changes: 0 additions & 35 deletions test/run.js
Original file line number Diff line number Diff line change
Expand Up @@ -181,44 +181,9 @@ function main (cb) {
// Windows can't handle npm rm npm due to file-in-use issues.
thingsToChain.push([exec, "npm rm npm"])
}
thingsToChain.push(publishTest)

chain(thingsToChain, cb)
}

function publishTest (cb) {
if (process.env.npm_package_config_publishtest !== "true") {
console.error("To test publishing: "+
"npm config set npm:publishtest true")
return cb()
}

chain
( [ setup
, [ execChain, packages.filter(function (p) {
return !p.match(/private/)
}).map(function (p) {
return [ "npm publish packages/"+p
, "npm install "+p
, "npm unpublish "+p+" --force"
]
}) ]
, publishPrivateTest
], cb )

}

function publishPrivateTest (cb) {
exec("npm publish packages/npm-test-private -s", true, function (er) {
if (er) {
exec( "npm unpublish npm-test-private --force"
, function (e2) {
cb(er || e2)
})
}
cleanup(cb)
})
}
}

main(function (er) {
Expand Down

0 comments on commit 8066571

Please sign in to comment.