mirror of
https://github.com/overleaf/overleaf.git
synced 2024-11-21 20:47:08 -05:00
Stub out noisy/slow logger-sharelatex and mongojs modules in tests
This commit is contained in:
parent
23dfe68cb8
commit
2a03591030
2 changed files with 2 additions and 1 deletions
|
@ -1,7 +1,6 @@
|
||||||
{db, ObjectId} = require "./mongojs"
|
{db, ObjectId} = require "./mongojs"
|
||||||
PackManager = require "./PackManager"
|
PackManager = require "./PackManager"
|
||||||
async = require "async"
|
async = require "async"
|
||||||
logger = require "logger-sharelatex"
|
|
||||||
|
|
||||||
module.exports = MongoManager =
|
module.exports = MongoManager =
|
||||||
getLastCompressedUpdate: (doc_id, callback = (error, update) ->) ->
|
getLastCompressedUpdate: (doc_id, callback = (error, update) ->) ->
|
||||||
|
|
|
@ -15,6 +15,8 @@ describe "MongoManager", ->
|
||||||
"./mongojs" : { db: @db = {}, ObjectId: ObjectId }
|
"./mongojs" : { db: @db = {}, ObjectId: ObjectId }
|
||||||
"./PackManager" : SandboxedModule.require packModulePath, requires:
|
"./PackManager" : SandboxedModule.require packModulePath, requires:
|
||||||
"./LockManager" : {}
|
"./LockManager" : {}
|
||||||
|
"./mongojs": {db: bson: BSON = sinon.stub(), ObjectId}
|
||||||
|
"logger-sharelatex": {}
|
||||||
@callback = sinon.stub()
|
@callback = sinon.stub()
|
||||||
@doc_id = ObjectId().toString()
|
@doc_id = ObjectId().toString()
|
||||||
@project_id = ObjectId().toString()
|
@project_id = ObjectId().toString()
|
||||||
|
|
Loading…
Reference in a new issue