test: add critical provider workflow coverage

This commit is contained in:
morluto
2026-07-25 15:12:51 +00:00
parent 521139d4a5
commit 4716fa2ece
10 changed files with 363 additions and 98 deletions
+7 -4
View File
@@ -48,7 +48,7 @@ export const ghidraBounded = (items: readonly JsonValue[]) => ({
next_offset: null,
});
export const ghidraNativeApiBoundary = () => ({
export const ghidraNativeApiBoundary = (mappingsTruncated = false) => ({
available: true as const,
provenance: "ghidra-high-function",
signature_source: "analysis",
@@ -115,7 +115,7 @@ export const ghidraNativeApiBoundary = () => ({
],
},
],
mappings_truncated: false,
mappings_truncated: mappingsTruncated,
limitations: [],
},
],
@@ -136,7 +136,10 @@ export const ghidraNativeApiBoundary = () => ({
],
});
export const ghidraFunctionDossier = (includeAssembly = true): JsonValue => {
export const ghidraFunctionDossier = (
includeAssembly = true,
mappingsTruncated = false,
): JsonValue => {
const pseudocode = "int fixture_main(void) { return 42; }";
return {
procedure: {
@@ -171,7 +174,7 @@ export const ghidraFunctionDossier = (includeAssembly = true): JsonValue => {
{ start: "0x401000", end: "0x401006", successors: [] },
]),
instruction_scan: { scanned: 2, truncated: false },
native_api: ghidraNativeApiBoundary(),
native_api: ghidraNativeApiBoundary(mappingsTruncated),
limitations: [
"Unresolved computed or indirect flows without target addresses are not represented as reference edges.",
"Thunk and external classifications are Ghidra FunctionManager observations; they do not resolve targetless calls.",