Permalink
Browse files

sandbox, feat: disable require.cache.

  • Loading branch information...
xicilion committed Aug 15, 2018
1 parent b8226c9 commit 8abefb0a69b54ba496ada5c2a99900d232a2a1f1
Showing with 2 additions and 2 deletions.
  1. +1 −1 fibjs/src/sandbox/SandBox_context.cpp
  2. +1 −1 test/vm_test.js
@@ -160,7 +160,7 @@ SandBox::Context::Context(SandBox* sb, exlib::string id)
m_fnRequest = isolate->NewFunction("require", _require, _mod);
m_fnRequest->Set(isolate->NewString("resolve"), isolate->NewFunction("resolve", _resolve, _mod));
m_fnRequest->Set(isolate->NewString("cache"), m_sb->mods());
// m_fnRequest->Set(isolate->NewString("cache"), m_sb->mods());
m_fnRun = isolate->NewFunction("run", _run, _mod);
}
View
@@ -540,7 +540,7 @@ describe("vm", () => {
}, sbox.modules)
});
it("require.cache", () => {
xit("require.cache", () => {
assert.isObject(require.cache);
});

0 comments on commit 8abefb0

Please sign in to comment.