aboutsummaryrefslogtreecommitdiffhomepage
path: root/backend/taskqueue/tasks.go
diff options
context:
space:
mode:
authornsfisis <nsfisis@gmail.com>2024-08-08 01:30:09 +0900
committernsfisis <nsfisis@gmail.com>2024-08-08 04:02:37 +0900
commit4eb7e89d6a77a4434bd087fbb86873521d30a8f5 (patch)
treeda13030d94538170a931747b957d2865bed03682 /backend/taskqueue/tasks.go
parent26378c2d2ad1f8cb3f20c7070be3be9a4f0a0ad6 (diff)
downloadiosdc-japan-2024-albatross-4eb7e89d6a77a4434bd087fbb86873521d30a8f5.tar.gz
iosdc-japan-2024-albatross-4eb7e89d6a77a4434bd087fbb86873521d30a8f5.tar.zst
iosdc-japan-2024-albatross-4eb7e89d6a77a4434bd087fbb86873521d30a8f5.zip
feat(backend): implement processTaskResults() partially
Diffstat (limited to 'backend/taskqueue/tasks.go')
-rw-r--r--backend/taskqueue/tasks.go6
1 files changed, 6 insertions, 0 deletions
diff --git a/backend/taskqueue/tasks.go b/backend/taskqueue/tasks.go
index 990ce65..cbe83b1 100644
--- a/backend/taskqueue/tasks.go
+++ b/backend/taskqueue/tasks.go
@@ -112,6 +112,8 @@ type TaskPayloadRunTestcase struct {
TaskPayloadBase
SubmissionID int
TestcaseID int
+ Stdin string
+ Stdout string
}
func newTaskRunTestcase(
@@ -120,6 +122,8 @@ func newTaskRunTestcase(
code string,
submissionID int,
testcaseID int,
+ stdin string,
+ stdout string,
) (*asynq.Task, error) {
payload, err := json.Marshal(TaskPayloadRunTestcase{
TaskPayloadBase: TaskPayloadBase{
@@ -129,6 +133,8 @@ func newTaskRunTestcase(
},
SubmissionID: submissionID,
TestcaseID: testcaseID,
+ Stdin: stdin,
+ Stdout: stdout,
})
if err != nil {
return nil, err