From 5bdc5a41c55ed687065305d362c58e4e8e44c3b7 Mon Sep 17 00:00:00 2001 From: IHsuan Date: Wed, 22 Nov 2017 16:39:05 +0800 Subject: [PATCH 1/2] add common.crashOnUnhandledRejection() in test.js --- test/addons/make-callback-recurse/test.js | 1 + tools/doc/node_modules/js-yaml/index.js | 12 ++---------- 2 files changed, 3 insertions(+), 10 deletions(-) diff --git a/test/addons/make-callback-recurse/test.js b/test/addons/make-callback-recurse/test.js index 77815e052ab1f9..222a81b06b87eb 100644 --- a/test/addons/make-callback-recurse/test.js +++ b/test/addons/make-callback-recurse/test.js @@ -9,6 +9,7 @@ const makeCallback = binding.makeCallback; // Make sure this is run in the future. const mustCallCheckDomains = common.mustCall(checkDomains); +common.crashOnUnhandledRejection(); // Make sure that using MakeCallback allows the error to propagate. assert.throws(function() { diff --git a/tools/doc/node_modules/js-yaml/index.js b/tools/doc/node_modules/js-yaml/index.js index 620bc293ffe032..13744352448b84 100644 --- a/tools/doc/node_modules/js-yaml/index.js +++ b/tools/doc/node_modules/js-yaml/index.js @@ -1,15 +1,7 @@ 'use strict'; -// Hack to load the js-yaml module from eslint. -// No other reason than that it’s huge. -const path = require('path'); +var yaml = require('./lib/js-yaml.js'); -const realJSYaml = path.resolve( - __dirname, '..', '..', '..', // tools/ - 'eslint', - 'node_modules', - 'js-yaml' -); -module.exports = require(realJSYaml); +module.exports = yaml; From 5cf6dc0b1d8ac06622e7b725274728a78eaed47f Mon Sep 17 00:00:00 2001 From: IHsuan Date: Sun, 26 Nov 2017 17:34:23 +0800 Subject: [PATCH 2/2] remove tools/doc/node_modules/js-yaml/index.js --- tools/doc/node_modules/js-yaml/index.js | 7 ------- 1 file changed, 7 deletions(-) delete mode 100644 tools/doc/node_modules/js-yaml/index.js diff --git a/tools/doc/node_modules/js-yaml/index.js b/tools/doc/node_modules/js-yaml/index.js deleted file mode 100644 index 13744352448b84..00000000000000 --- a/tools/doc/node_modules/js-yaml/index.js +++ /dev/null @@ -1,7 +0,0 @@ -'use strict'; - - -var yaml = require('./lib/js-yaml.js'); - - -module.exports = yaml;