mirror of
https://github.com/ether/etherpad-lite.git
synced 2026-05-07 13:16:36 +02:00
tests: Fix handling of nullish module definitions
This commit is contained in:
parent
9987834b15
commit
c8e544ec8d
@ -214,7 +214,7 @@ $(() => (async () => {
|
||||
const [origDefs] = args;
|
||||
const defs = {};
|
||||
for (const [path, origDef] of Object.entries(origDefs)) {
|
||||
defs[path] = function (require, exports, module) {
|
||||
defs[path] = origDef == null ? origDef : function (require, exports, module) {
|
||||
const calls = [];
|
||||
mochaCalls.set(module.id.replace(/\.js$/, ''), calls);
|
||||
// Backup Mocha functions. Note that because modules can require other modules, these
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user