mcptest

package
v0.3.6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 20, 2026 License: MIT Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Env

type Env struct {
	Session *mcp.ClientSession
	Store   *store.Store

	// RescanDir is the source dir a NewEnvWithRescan loop watches; "" otherwise.
	RescanDir string

	// WorkspaceDir is the source dir whose .remindb/ holds the session ledger.
	WorkspaceDir string
	// contains filtered or unexported fields
}

func NewEnv

func NewEnv(t *testing.T) *Env

func NewEnvWithLog added in v0.3.4

func NewEnvWithLog(t *testing.T) *Env

func NewEnvWithRescan added in v0.3.4

func NewEnvWithRescan(t *testing.T) *Env

func NewEnvWithSessionLedger added in v0.3.5

func NewEnvWithSessionLedger(t *testing.T) *Env

func NewEnvWithSessionLogs added in v0.3.5

func NewEnvWithSessionLogs(t *testing.T) *Env

NewEnvWithSessionLogs wires the production session-log chain: WithSourceDir (so the registry middleware injects the session id) plus a logger whose outermost handler is sessionlog.Handler over an Info-gated discard stream — the same shape cmd/remindb/serve.go builds when session_files is enabled.

func NewHttpEnv added in v0.2.0

func NewHttpEnv(t *testing.T) *Env

func (*Env) CallTool

func (e *Env) CallTool(t *testing.T, name string, args map[string]any) *mcp.CallToolResult

func (*Env) FlushSessions added in v0.3.5

func (e *Env) FlushSessions()

FlushSessions forces a session-ledger flush so tests observe it deterministically.

func (*Env) ReadResource added in v0.3.4

func (e *Env) ReadResource(t *testing.T, uri string) string

func (*Env) TextContent

func (e *Env) TextContent(t *testing.T, result *mcp.CallToolResult) string

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL