From b38648deafcc746841cd4806cd4a933d5573a88c Mon Sep 17 00:00:00 2001 From: Kenneth Aasan Date: Thu, 14 Mar 2024 15:38:03 +0100 Subject: [PATCH] fix: fixes tests for windows --- test/generators/FileGenerators.spec.ts | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/test/generators/FileGenerators.spec.ts b/test/generators/FileGenerators.spec.ts index dad768d0ae..948b79e0a6 100644 --- a/test/generators/FileGenerators.spec.ts +++ b/test/generators/FileGenerators.spec.ts @@ -142,9 +142,7 @@ describe.each(generatorsToTest)( .at(0) .at(1); expect(filePath).toMatch(expectedOutputDirPath); - expect( - filePath.replace(`${expectedOutputDirPath}/`, '') - ).toMatchSnapshot(); + expect(path.basename(filePath)).toMatchSnapshot(); expect( (FileHelpers.writerToFileSystem as jest.Mock).mock.calls.at(0).at(2) ).toEqual(false);