Replace manual tmp file creation with tmp library which uses security best practices

This commit is contained in:
Jessica Rudder
2025-08-12 13:49:47 -07:00
parent a62dfeda7b
commit 3ba8e1b39d
6 changed files with 924 additions and 53 deletions
+1 -1
View File
@@ -66,7 +66,7 @@ function mockInputs(inputs: Record<string, string> = {}): void {
*/
function verifyStandardResponse(): void {
expect(core.setOutput).toHaveBeenNthCalledWith(1, 'response', 'Hello, user!')
expect(core.setOutput).toHaveBeenNthCalledWith(2, 'response-file', expect.stringContaining('modelResponse.txt'))
expect(core.setOutput).toHaveBeenNthCalledWith(2, 'response-file', expect.stringContaining('modelResponse-'))
}
vi.mock('fs', () => ({