MCPcopy Create free account
hub / github.com/astercloud/aster / TestInMemoryStore_InvalidNamespace

Function TestInMemoryStore_InvalidNamespace

pkg/memory/logic/store_test.go:380–391  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

378}
379
380func TestInMemoryStore_InvalidNamespace(t *testing.T) {
381 store := NewInMemoryStore()
382 defer func() { _ = store.Close() }()
383
384 ctx := context.Background()
385
386 err := store.Save(ctx, &LogicMemory{
387 Namespace: "", // 空 namespace
388 Key: "test",
389 })
390 assert.ErrorIs(t, err, ErrInvalidNamespace)
391}

Callers

nothing calls this directly

Calls 3

CloseMethod · 0.95
SaveMethod · 0.95
NewInMemoryStoreFunction · 0.70

Tested by

no test coverage detected