Files
archie/internal/domain/workflow/routing_test.go
T
sam a27d430215 feat(logging,workflow): daemon log feed and executable workflow registry
Add internal/logging.Feed, a logging-owned bounded replay buffer separate
from the persisted task-lifecycle event stream, with a live SSE endpoint.
Expose the executable workflow registry (skillbuild.Catalog) including
zero-run definitions and their origin (builtin vs. installed skill), not
just historical run statistics. Route() now returns an explicit failure
workflow for an unknown pre-assigned workflow name instead of silently
falling through to label-based routing.

Fixes #54
2026-08-09 01:26:10 +10:00

16 lines
416 B
Go

package workflow
import (
"testing"
"github.com/samcharles93/archie-core/internal/store"
)
func TestRouteDoesNotSilentlyReplaceAnAdmittedWorkflow(t *testing.T) {
task := &store.Task{Workflow: "skill-review"}
wf := Route(task, Registry{"implement": Implement()})
if wf.Name != "none" || len(wf.Stages) != 1 || wf.Stages[0].Name != "fail" {
t.Fatalf("Route() = %#v, want explicit failure workflow", wf)
}
}