From 301e02f067140d94bc2ad56880cf4750fdadfa25 Mon Sep 17 00:00:00 2001 From: Maximilian Harz Date: Tue, 10 Jun 2025 13:22:27 +0200 Subject: [PATCH] Add comment why tests are skipped --- src/Utils/getImageDimensions.spec.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Utils/getImageDimensions.spec.ts b/src/Utils/getImageDimensions.spec.ts index 5cd6350e..80688cd6 100644 --- a/src/Utils/getImageDimensions.spec.ts +++ b/src/Utils/getImageDimensions.spec.ts @@ -1,3 +1,5 @@ +/* Currently this test suite is skipped due to the need for a browser environment. We could set + up a headless browser test environment in the future, e.g. https://vitest.dev/guide/browser/ */ import { readFileSync } from 'node:fs' import path from 'node:path' @@ -12,8 +14,6 @@ const testImages = testImagePaths.map((imagePath) => readFileSync(path.join(__dirname, '../../', imagePath)), ) -// vi.spyOn(global, 'FileReader').mockImplementation((fileReader: FileReader) => fileReader) - describe('getImageDimensions', () => { it.skip('returns the correct dimensions for a valid image file', async () => { const file = new File([testImages[0]], 'image1.jpg', { type: 'image/jpeg' })