From 6f83ccd04473d276f1817a0cf552fea674a172c8 Mon Sep 17 00:00:00 2001 From: Laurent Cozic Date: Sat, 13 Jan 2024 19:10:34 +0000 Subject: [PATCH] Chore: Try to fix random test timeout --- packages/lib/services/ocr/OcrService.test.ts | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/packages/lib/services/ocr/OcrService.test.ts b/packages/lib/services/ocr/OcrService.test.ts index bc623ca8c..d92bd14c2 100644 --- a/packages/lib/services/ocr/OcrService.test.ts +++ b/packages/lib/services/ocr/OcrService.test.ts @@ -75,7 +75,12 @@ describe('OcrService', () => { expect(processedResource2.updated_time).toBeGreaterThan(resource2.updated_time); await service.dispose(); - }); + + // On CI these tests can randomly throw the error "Exceeded timeout of + // 90000 ms for a test.". So for now increase the timeout and if that's + // not sufficient it means the test is simply stuck, and we should use + // `jest.retryTimes(2)` + }, 60000 * 5); it('should process PDF resources', async () => { const { resource } = await createNoteAndResource({ path: `${ocrSampleDir}/dummy.pdf` });