public void testChrootGlobalModule()
throws InterruptedException, ExecutionException, NodeException
{
Sandbox sb = new Sandbox();
sb.setFilesystemRoot("./target/test-classes");
NodeScript script = env.createScript("globalmoduletest.js",
new File("./target/test-classes/tests/globalmoduletest.js"), null);
HashMap<String, String> env = new HashMap<String, String>();
env.put("NODE_PATH", "./global");
script.setEnvironment(env);
script.setSandbox(sb);
ScriptStatus status = script.execute().get();
assertEquals(0, status.getExitCode());
script.close();
}