diff --git a/src/browser/ElectronFileScope.cleanup.test.ts b/src/browser/ElectronFileScope.cleanup.test.ts index 54fa57d25f..ab7670d6b1 100644 --- a/src/browser/ElectronFileScope.cleanup.test.ts +++ b/src/browser/ElectronFileScope.cleanup.test.ts @@ -237,7 +237,7 @@ it("keeps cancellation primary when ASAR close fails, then retries the same hand expect(mapped?.cleanupPrimary?.cause).toBe(reason); await expect(authorizedElectronFile(location)).resolves.toBe( - `${handleState.archive}/index.html`, + fileURLToPath(location), ); expect(handleState.events).toEqual([ "open", @@ -275,7 +275,7 @@ it("keeps an earlier read failure primary over a later abort and close failure", expect(mapped?.cleanupPrimary?.cause).toBe(readFailure); await expect(authorizedElectronFile(location)).resolves.toBe( - `${handleState.archive}/index.html`, + fileURLToPath(location), ); expect(mapped?.cleanupIncomplete).toBe(false); }); @@ -304,7 +304,7 @@ it("preserves an arbitrary cancellation reason observed during ASAR read", async expect(mapped?.cleanupPrimary?.cause).toBe(reason); await expect(authorizedElectronFile(location)).resolves.toBe( - `${handleState.archive}/index.html`, + fileURLToPath(location), ); expect(mapped?.cleanupIncomplete).toBe(false); }); @@ -333,7 +333,7 @@ it("preserves cancellation observed after ASAR stat when final close fails", asy expect(mapped?.cleanupPrimary?.cause).toBe(reason); await expect(authorizedElectronFile(location)).resolves.toBe( - `${handleState.archive}/index.html`, + fileURLToPath(location), ); expect(mapped?.cleanupIncomplete).toBe(false); });