Harden runner and test timing coverage#107
Merged
ryansimmen merged 9 commits intomainfrom Apr 25, 2026
Merged
Conversation
Adds missing conventional GoDoc comments for exported frontmatter metadata and queue compatibility symbols. The queue compatibility comments clarify that aliases and wrappers forward to queueview behavior. Task-ID: add-missing-godoc-comments Affects: internal/frontmatter/frontmatter.go, internal/queue/compat.go
Add direct queueview tests for empty diagnostics, cycles, mixed issue reporting, and completed dependency aliases. This keeps dependency analysis regression coverage close to DiagnoseDependencies without relying on the compat layer. Task-ID: add-queueview-diagnostics-tests Affects: internal/queueview/diagnostics_test.go
Adds a local time seam for session metadata timestamps so unchanged-session behavior can be tested deterministically. The test now compares persisted content and updated_at values instead of waiting on filesystem mtime granularity. Task-ID: remove-session-test-sleep Affects: internal/runtimedata/session.go, internal/runtimedata/session_test.go
Extract the status watch redraw loop behind a tick-channel helper so tests can trigger refreshes deterministically while public watch APIs continue using a real ticker. Active file claims showed the status watch files reserved for this same task, and the change stays within that claimed scope. Task-ID: remove-status-watch-test-sleeps Affects: internal/status/status.go, internal/status/status_test.go
Replaces scheduler-dependent sleeps in messaging concurrency tests with explicit start barriers, bounded polling, and deletion/write handoffs. This keeps the race coverage deterministic without changing production messaging code. Task-ID: remove-messaging-test-sleeps Affects: internal/messaging/messaging_test.go
Runner shutdown recovery now threads cancellation into stuck-task recovery so cancelled agents return tasks to backlog without generic failure markers. Added targeted coverage for pause state handling, bounded-run state detection, bounded-run errors, and cancelled recovery. Task-ID: harden-runner-shutdown-and-bounded-run Affects: internal/runner/runner_poll.go, internal/runner/task.go, internal/runner/runner_test.go, internal/runner/task_test.go
Centralizes duplicated non-buffering writer and verdict JSON test fixtures in internal/testutil. Converts taskfile branch parser tests to an external package to avoid a test-only import cycle from the shared verdict helper. Task-ID: add-shared-test-fixture-helpers Affects: internal/testutil/testutil.go, cmd/mato/main_test.go, internal/doctor/render_test.go, internal/graph/graph_test.go, internal/graph/render_test.go, internal/history/history_test.go, internal/inspect/inspect_test.go, internal/queueview/index_test.go
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Testing