UNPKG

downgrade

Version:

Sets the user identity of the process to `www-data`

13 lines (11 loc) 261 B
var test = require('tape') var downgrade = require('../') test('basic usage', function (t) { var currentUser = process.getuid() t.doesNotThrow(function () { downgrade('nobody') downgrade() }) t.ok(process.getuid() !== currentUser) t.end() })