diff --git a/tests/boundary/providers/native/keyedArchiveEncoding.test.ts b/tests/boundary/providers/native/keyedArchiveEncoding.test.ts index c32a6e0372..b62061cbb6 100644 --- a/tests/boundary/providers/native/keyedArchiveEncoding.test.ts +++ b/tests/boundary/providers/native/keyedArchiveEncoding.test.ts @@ -15,13 +15,15 @@ it.each(["utf8", "utf8-bom", "utf16le", "utf16be", "binary"] as const)( const root = await createTestTempDirectory("rea-keyed-encoding-"); const xml = await nativeFixture("archive-xml-encoding/archive.xml"); const utf16 = Buffer.from(xml.replace("UTF-8", "UTF-16"), "utf16le"); + // The binary builder emits type-8 records for UID; CF$UID is XML's convention. + const binarySource = xml.replaceAll("CF$UID", "UID"); const bytes = encoding === "utf8" ? Buffer.from(xml) : encoding === "utf8-bom" ? Buffer.concat([Buffer.from([0xef, 0xbb, 0xbf]), Buffer.from(xml)]) : encoding === "binary" - ? Buffer.from(buildBinary(parse(xml))) + ? Buffer.from(buildBinary(parse(binarySource))) : Buffer.concat([ Buffer.from( encoding === "utf16le" ? [0xff, 0xfe] : [0xfe, 0xff], @@ -65,6 +67,8 @@ it.each(["utf8-as-utf16", "utf16-as-utf8"] as const)( async (kind) => { const root = await createTestTempDirectory("rea-keyed-encoding-"); const xml = await nativeFixture("archive-xml-encoding/archive.xml"); + // The binary builder emits type-8 records for UID; CF$UID is XML's convention. + const binarySource = xml.replaceAll("CF$UID", "UID"); const bytes = kind === "utf8-as-utf16" ? Buffer.from(xml.replace("UTF-8", "UTF-16")) diff --git a/tests/boundary/providers/native/nativeDmgArtifactReader.test.ts b/tests/boundary/providers/native/nativeDmgArtifactReader.test.ts index ecc87ff129..99f43b3052 100644 --- a/tests/boundary/providers/native/nativeDmgArtifactReader.test.ts +++ b/tests/boundary/providers/native/nativeDmgArtifactReader.test.ts @@ -1037,6 +1037,7 @@ describe("DMG attach cancellation and preexisting mounts", () => { }, ); + it("leaves a preexisting outside-root mount attached", async () => { const calls: string[][] = []; const host: NativeDmgHost = { diff --git a/tests/fixtures/keyedArchiveNumberMetadata.ts b/tests/fixtures/keyedArchiveNumberMetadata.ts index 79ba543e3a..c9eeaceb68 100644 --- a/tests/fixtures/keyedArchiveNumberMetadata.ts +++ b/tests/fixtures/keyedArchiveNumberMetadata.ts @@ -94,11 +94,14 @@ export const archiveNumberMetadataCases: readonly MetadataCase[] = [ malformedReference: false, }, { - name: `${key} malformed numeric reference`, + name: + key === "CF$UID" + ? `${key} malformed numeric reference` + : `${key} unsafe integer dictionary data`, source: { [key]: "__INTEGER__" }, element: "", - expected: { [key]: ROUNDED }, - malformedReference: true, + expected: { [key]: key === "CF$UID" ? ROUNDED : EXACT_INTEGER }, + malformedReference: key === "CF$UID", }, ]), {