test(hooks): cover pre-compact-scan happy-path, modes, size-cap
This commit is contained in:
parent
e3aba9bab5
commit
474e6217f4
4 changed files with 128 additions and 1 deletions
|
|
@ -141,7 +141,10 @@ try {
|
|||
process.exit(0);
|
||||
}
|
||||
|
||||
const injectionFindings = scanForInjection(transcriptText) || [];
|
||||
const injectionResult = scanForInjection(transcriptText) || { patterns: [] };
|
||||
const injectionFindings = Array.isArray(injectionResult.patterns)
|
||||
? injectionResult.patterns.map((p) => ({ type: 'injection', label: p.label, severity: p.severity }))
|
||||
: [];
|
||||
const secretFindings = scanForSecrets(transcriptText);
|
||||
const allFindings = [...injectionFindings, ...secretFindings];
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue