mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
821972b791
Configure chai and SandboxedModule in a central place and add SandboxedModule globals that are required in Node 12.
21 lines
400 B
JavaScript
21 lines
400 B
JavaScript
const chai = require('chai')
|
|
const SandboxedModule = require('sandboxed-module')
|
|
|
|
// Chai configuration
|
|
chai.should()
|
|
|
|
// SandboxedModule configuration
|
|
SandboxedModule.configure({
|
|
requires: {
|
|
'logger-sharelatex': {
|
|
debug() {},
|
|
log() {},
|
|
info() {},
|
|
warn() {},
|
|
err() {},
|
|
error() {},
|
|
fatal() {}
|
|
}
|
|
},
|
|
globals: { Buffer, JSON, console, process }
|
|
})
|