9p: update imports for agent/ package extraction

Import ollie/agent for types that moved from ollie/session:
AgentConfig, BuildRuntime, Event, PersistedAgent, Load, etc.

Remove ollie/session imports from files that no longer need it.
Fix test helpers to provide NewDispatcher (required by Agent).
This commit is contained in:
Levi Neely 2026-07-29 21:49:15 +02:00
parent e630714403
commit e16e14bed7
2 changed files with 8 additions and 0 deletions

BIN
fs.test Executable file

Binary file not shown.

View File

@ -13,6 +13,7 @@ import (
"ollie/session"
"ollie/agent"
"ollie/tools"
"ollie/backend"
olog "ollie/log"
"olliesrv/fs"
@ -34,6 +35,7 @@ func newNoopCore(id string) *session.Session {
NewBackend: func(name string) (backend.Backend, error) {
return backend.NewNoop(name, "default"), nil
},
NewDispatcher: func() tools.Dispatcher { return tools.NewDispatcher() },
})
}
@ -57,6 +59,7 @@ func newBlockingCore(id string) *session.Session {
NewBackend: func(name string) (backend.Backend, error) {
return backend.NewNoop(name, "default"), nil
},
NewDispatcher: func() tools.Dispatcher { return tools.NewDispatcher() },
})
}
@ -78,6 +81,7 @@ func newContentCore(id, content string) *session.Session {
NewBackend: func(name string) (backend.Backend, error) {
return backend.NewNoop(name, "default"), nil
},
NewDispatcher: func() tools.Dispatcher { return tools.NewDispatcher() },
})
}
@ -122,6 +126,7 @@ func newTestSessionManagerWithCore(t *testing.T) *mgr.Manager {
NewBackend: func(name string) (backend.Backend, error) {
return backend.NewNoop(name, "default"), nil
},
NewDispatcher: func() tools.Dispatcher { return tools.NewDispatcher() },
}), nil
},
})
@ -856,6 +861,7 @@ func TestSessionFileStoreMakePublishMultipleEvents(t *testing.T) {
AgentName: "default",
CWD: "/tmp",
SessionID: "s1",
NewDispatcher: func() tools.Dispatcher { return tools.NewDispatcher() },
})
ctx, cancel := context.WithCancel(context.Background())
defer cancel()
@ -1150,6 +1156,7 @@ func TestSessionManagerCreateSessionEnvExpansion(t *testing.T) {
AgentName: agentName,
CWD: cwd,
SessionID: sessionID,
NewDispatcher: func() tools.Dispatcher { return tools.NewDispatcher() },
}), nil
},
})
@ -1173,6 +1180,7 @@ func TestSessionManagerCreateSessionTildeExpansion(t *testing.T) {
AgentName: agentName,
CWD: cwd,
SessionID: sessionID,
NewDispatcher: func() tools.Dispatcher { return tools.NewDispatcher() },
}), nil
},
})