| 1496 | } |
| 1497 | |
| 1498 | func pluginProtocolTestOutcome( |
| 1499 | info *relaycommon.RelayInfo, |
| 1500 | pluginKey string, |
| 1501 | taskID string, |
| 1502 | _ ...any, |
| 1503 | ) *taskSubmissionOutcome { |
| 1504 | return &taskSubmissionOutcome{ |
| 1505 | Result: &relay.TaskSubmitResult{}, |
| 1506 | Task: &model.Task{ |
| 1507 | TaskID: taskID, |
| 1508 | Platform: constant.TaskPlatform(pluginKey), |
| 1509 | UserId: info.UserId, |
| 1510 | Status: model.TaskStatusSubmitted, |
| 1511 | CreatedAt: 1_710_000_000, |
| 1512 | }, |
| 1513 | RelayInfo: info, |
| 1514 | } |
| 1515 | } |
| 1516 | |
| 1517 | func pluginProtocolTestSSEEventTypes(body string) []string { |
| 1518 | lines := strings.Split(body, "\n") |