Flush project before getting all project labels

This commit is contained in:
Shane Kilkelly
2017-06-13 11:15:26 +01:00
parent bd6133aadb
commit a3dbb16e50
2 changed files with 7 additions and 6 deletions
@@ -105,6 +105,7 @@ describe 'LabelsHandler', ->
'doc_one': {lines: ['\\label{aaa}']}
}
@fakeLabels = ['aaa']
@DocumentUpdaterHandler.flushProjectToMongo = sinon.stub().callsArgWith(1, null)
@ProjectEntityHandler.getAllDocs = sinon.stub().callsArgWith(1, null, @fakeDocs)
@LabelsHandler.extractLabelsFromProjectDocs = sinon.stub().returns(@fakeLabels)
@call = (callback) =>