From 9f3c0c1c622b83453b59071f09f3c89a85f4bae5 Mon Sep 17 00:00:00 2001 From: Steve Hetzel Date: Tue, 24 Oct 2023 11:07:36 -0600 Subject: [PATCH] fix: only posix paths added via createMockZip --- test/mock/client/index.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/test/mock/client/index.ts b/test/mock/client/index.ts index fcf8b42b54..046c341a7e 100644 --- a/test/mock/client/index.ts +++ b/test/mock/client/index.ts @@ -9,7 +9,9 @@ import * as JSZip from 'jszip'; export async function createMockZip(entries: string[]): Promise { const zip = JSZip(); for (const entry of entries) { - zip.file(entry, ''); + // Ensure only posix paths are added to zip files + const relPosixPath = entry.replace(/\\/g, '/'); + zip.file(relPosixPath, ''); } return zip.generateAsync({ type: 'nodebuffer',