mirror of
https://github.com/yu-i-i/overleaf-cep.git
synced 2026-11-15 14:43:46 +01:00
[clsi] initial implementation of compile from history (#31883)
* [clsi] initial implementation of compile from history * [clsi] copy changes * [saas-e2e] extend test case with nested folder * [saas-e2e] add test case for tracked changes * [web] fix accumulating changes from multiple chunks * [web] optimize size check for compile request payload * [clsi] deduplicate globalBlobs * [clsi] add validation for request body details * [clsi] add metrics for compile from history * [clsi] download binary files concurrently * [clsi] skip download of empty file blob * [clsi] break down e2e compile time metric by compileFromHistory GitOrigin-RevId: 0dadef93e89d8a172c35cb130a1042d9d1bec42a
This commit is contained in:
@@ -21,6 +21,14 @@ describe('ProjectPersistenceManager', () => {
|
||||
default: (ctx.UrlCache = {}),
|
||||
}))
|
||||
|
||||
vi.doMock(
|
||||
'../../../app/js/HistoryResourceWriter',
|
||||
() =>
|
||||
(ctx.HistoryResourceWriter = {
|
||||
clearCacheCb: sinon.stub().yields(null),
|
||||
})
|
||||
)
|
||||
|
||||
vi.doMock('../../../app/js/CompileManager', () => ({
|
||||
default: (ctx.CompileManager = {}),
|
||||
}))
|
||||
@@ -163,6 +171,13 @@ describe('ProjectPersistenceManager', () => {
|
||||
.should.equal(true)
|
||||
})
|
||||
|
||||
it('should clear the history cache', ctx => {
|
||||
ctx.HistoryResourceWriter.clearCacheCb.should.have.been.calledWith(
|
||||
ctx.project_id,
|
||||
ctx.user_id
|
||||
)
|
||||
})
|
||||
|
||||
it('should clear all the cached Urls for the project', ctx => {
|
||||
return ctx.UrlCache.clearProject
|
||||
.calledWith(ctx.project_id)
|
||||
|
||||
Reference in New Issue
Block a user