test: fix test case issue

This commit is contained in:
Marvin Zhang
2024-11-22 13:59:12 +08:00
parent 9f1d7dd385
commit a6e845a9bf
2 changed files with 10 additions and 5 deletions

View File

@@ -809,7 +809,8 @@ func (r *Runner) startIPCReader() {
line := scanner.Text()
var ipcMsg IPCMessage
if err := json.Unmarshal([]byte(line), &ipcMsg); err == nil && ipcMsg.IPC {
err := json.Unmarshal([]byte(line), &ipcMsg)
if err == nil && ipcMsg.IPC {
// Only handle as IPC if it's valid JSON AND has IPC flag set
if r.ipcHandler != nil {
r.ipcHandler(ipcMsg)