#rewire-global
Hook rewire into every required package.
$ npm install rewire-global --save-dev
require('rewire-global').enable();
var myModule = require('./my-module');
var myFunc = myModule.__get__('myFunc');
Rewire is enabled globally for all modules in node.
#rewire-global
Hook rewire into every required package.
$ npm install rewire-global --save-dev
require('rewire-global').enable();
var myModule = require('./my-module');
var myFunc = myModule.__get__('myFunc');
Rewire is enabled globally for all modules in node.