You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Native .node modules cannot be loaded more than once.
require('./some-lib.node');
delete require('module')._cache[<some-lib's module ID>];
require('./some-lib.node');
// Error: Module did not self-register.
Mockery will have to cache native modules no matter what, so that they're never loaded more than once. They can still be substituted and mocked. The only problem is if a native module require()s some dependencies, but I don't think that happens in practice.
Native .node modules cannot be loaded more than once.
Mockery will have to cache native modules no matter what, so that they're never loaded more than once. They can still be substituted and mocked. The only problem is if a native module require()s some dependencies, but I don't think that happens in practice.
See also: mfncooper#34
The text was updated successfully, but these errors were encountered: