|
@ -28,7 +28,7 @@ var callbacks = 0; |
|
|
|
|
|
|
|
|
function test(env, cb) { |
|
|
function test(env, cb) { |
|
|
var filename = path.join(common.fixturesDir, 'test-fs-readfile-error.js'); |
|
|
var filename = path.join(common.fixturesDir, 'test-fs-readfile-error.js'); |
|
|
var execPath = process.execPath + ' --throw-deprecation ' + filename; |
|
|
var execPath = process.execPath + ' ' + filename; |
|
|
var options = { env: env || {} }; |
|
|
var options = { env: env || {} }; |
|
|
exec(execPath, options, function(err, stdout, stderr) { |
|
|
exec(execPath, options, function(err, stdout, stderr) { |
|
|
assert(err); |
|
|
assert(err); |
|
@ -53,12 +53,3 @@ test({ NODE_DEBUG: 'fs' }, function(data) { |
|
|
process.on('exit', function() { |
|
|
process.on('exit', function() { |
|
|
assert.equal(callbacks, 2); |
|
|
assert.equal(callbacks, 2); |
|
|
}); |
|
|
}); |
|
|
|
|
|
|
|
|
(function() { |
|
|
|
|
|
console.error('the warnings are normal here.'); |
|
|
|
|
|
// just make sure that this doesn't crash the process.
|
|
|
|
|
|
var fs = require('fs'); |
|
|
|
|
|
fs.readFile(__dirname); |
|
|
|
|
|
fs.readdir(__filename); |
|
|
|
|
|
fs.unlink('gee-i-sure-hope-this-file-isnt-important-or-existing'); |
|
|
|
|
|
})(); |
|
|
|
|
|