From fa9994094540aeba33e4fa74f2dac74d00c42a4b Mon Sep 17 00:00:00 2001 From: Maurice Date: Fri, 20 Nov 2026 19:15:48 +0100 Subject: [PATCH] test(platform): a share-token photo whose copy fails to build is a 404 --- server/tests/unit/nest/platform.controller.test.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/server/tests/unit/nest/platform.controller.test.ts b/server/tests/unit/nest/platform.controller.test.ts index efca3efb9..3f7dee995 100644 --- a/server/tests/unit/nest/platform.controller.test.ts +++ b/server/tests/unit/nest/platform.controller.test.ts @@ -390,6 +390,11 @@ describe('applyPlatformUploads', () => { expect(refused.statusCode).toBe(404); expect(refused.body).toBe('Not found'); + renditionFor.mockRejectedValue(new Error('storage down')); + const failed = makeRes(); + await photoHandler()(ask, failed, next); + expect(failed.statusCode).toBe(404); + const unwired = makeRes(); await photoHandler(null)(ask, unwired, next); expect(unwired.statusCode).toBe(404);