MCPcopy Create free account
hub / github.com/compozy/agh / PauseTask

Method PauseTask

internal/task/scheduler_controls_test.go:34–49  ·  view source on GitHub ↗
(ctx context.Context, mutation PauseMutation)

Source from the content-addressed store, hash-verified

32}
33
34func (s *schedulerControlTestStore) PauseTask(ctx context.Context, mutation PauseMutation) (Task, error) {
35 if err := ctx.Err(); err != nil {
36 return Task{}, err
37 }
38 record, err := s.GetTask(ctx, mutation.TaskID)
39 if err != nil {
40 return Task{}, err
41 }
42 record.Paused = true
43 record.PausedBy = mutation.Actor
44 record.PausedAt = mutation.PausedAt
45 record.PausedReason = mutation.Reason
46 record.UpdatedAt = mutation.PausedAt
47 s.tasks[record.ID] = record
48 return record, nil
49}
50
51func (s *schedulerControlTestStore) ResumeTask(ctx context.Context, mutation ResumeMutation) (Task, error) {
52 if err := ctx.Err(); err != nil {

Callers

nothing calls this directly

Calls 2

GetTaskMethod · 0.65
ErrMethod · 0.45

Tested by

no test coverage detected