refactor(artifacts): remove selectors and traversal quotas
This commit is contained in:
@@ -14,14 +14,6 @@ import {
|
||||
import { createEvidence } from "../../../src/domain/evidence.js";
|
||||
import { jsonValueSchema } from "../../../src/domain/jsonValue.js";
|
||||
|
||||
const LIMITS = {
|
||||
maxEntries: 1_000,
|
||||
maxTotalBytes: 1024 * 1024,
|
||||
maxEntryBytes: 1024 * 1024,
|
||||
maxCompressionRatio: 100,
|
||||
maxDepth: 20,
|
||||
maxPathBytes: 1024,
|
||||
} as const;
|
||||
const PROVIDER = {
|
||||
id: "rea-artifact-graph",
|
||||
name: "REA artifact graph",
|
||||
@@ -29,7 +21,7 @@ const PROVIDER = {
|
||||
} as const;
|
||||
|
||||
const observe = async (path: string) => {
|
||||
const inventory = await inventoryArtifact(path, LIMITS);
|
||||
const inventory = await inventoryArtifact(path);
|
||||
return createEvidence(
|
||||
{
|
||||
path,
|
||||
|
||||
@@ -164,14 +164,7 @@ it("keeps ASAR analysis usable when unpacked native companion bytes are absent",
|
||||
await createPackageWithOptions(source, archive, { unpack: "**/*.node" });
|
||||
await rm(join(`${archive}.unpacked`, "native", "addon.node"));
|
||||
|
||||
const snapshot = await scanArtifactInventory(archive, {
|
||||
maxEntries: 8_000,
|
||||
maxTotalBytes: 512 * 1024 * 1024,
|
||||
maxEntryBytes: 128 * 1024 * 1024,
|
||||
maxCompressionRatio: 1_000,
|
||||
maxDepth: 64,
|
||||
maxPathBytes: 4_096,
|
||||
});
|
||||
const snapshot = await scanArtifactInventory(archive);
|
||||
const missingNative = snapshot.occurrences.find(
|
||||
({ logical_path }) => logical_path === "native/addon.node",
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user