refactor(elf): consolidate kernel module checks on positional reads

This commit is contained in:
morluto committed 2026-11-23 01:18:06 -05:00
1 parent 40200aea6f
commit be32625b29
8 files changed
+237 -452

No files matched your search

@@ -102,19 +102,6 @@ it("rejects relative paths, extra arguments and invalid field budgets before rea
expect(calls).toBe(0);
});
it("records an applicable module and its x86_64 architecture", async () => {
const result = await new KernelModuleService({
identity,
inspect: () => Promise.resolve(ok(report)),
}).inspect({ path: report.artifact.path });
if (!result.ok) throw result.error;
expect(result.value).toMatchObject({
confidence: "observed",
subject: { identity: { format: "elf", architecture: "x86_64" } },
normalized_result: report,
});
});
it("rejects a report whose entry count does not match the examined sections", async () => {
const result = await new KernelModuleService({
identity,