sessionstoretest

package
v0.0.0-...-fa87db7 Latest Latest
Warning

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

Go to latest
Published: Jun 12, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package sessionstoretest provides a shared conformance suite for SessionStore adapters. Call RunSessionStoreConformance from a *testing.T to assert the behavioral contracts every adapter must satisfy. It is the Go port of the Python SDK's run_session_store_conformance.

Index

Constants

View Source
const (
	OptListSessions         = "list_sessions"
	OptListSessionSummaries = "list_session_summaries"
	OptDelete               = "delete"
	OptListSubkeys          = "list_subkeys"
)

Optional capability names accepted in the skipOptional argument. They mirror the Python optional methods on SessionStore.

Variables

This section is empty.

Functions

func RunSessionStoreConformance

func RunSessionStoreConformance(t *testing.T, factory func() claude.SessionStore, skipOptional ...string)

RunSessionStoreConformance asserts the SessionStore behavioral contracts against the store produced by factory. factory is invoked once per contract to provide isolation. Contracts for optional capabilities (ListableStore, SummarizableStore, DeletableStore, SubkeyListableStore) are skipped when the store does not implement the interface, or when the corresponding name is passed in skipOptional. An unknown skipOptional name fails the test.

Types

This section is empty.

Jump to

Keyboard shortcuts

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