MCPcopy Index your code
hub / github.com/apache/answer / assertNotFound

Function assertNotFound

plugin/plugin_test/kv_storage_test.go:62–70  ·  view source on GitHub ↗
(t *testing.T, kv *plugin.KVOperator, ctx context.Context, group, key string)

Source from the content-addressed store, hash-verified

60}
61
62func assertNotFound(t *testing.T, kv *plugin.KVOperator, ctx context.Context, group, key string) {
63 val, err := kv.Get(ctx, plugin.KVParams{Group: group, Key: key})
64 if err != plugin.ErrKVKeyNotFound {
65 t.Errorf("Expected ErrKVKeyNotFound for %s/%s, got: %v", group, key, err)
66 }
67 if val != "" {
68 t.Errorf("Expected empty value for %s/%s, got: '%s'", group, key, val)
69 }
70}
71
72func assertError(t *testing.T, err error, expected error, msg string) {
73 if err != expected {

Callers 2

TestBasicOperationsFunction · 0.85
TestTransactionsFunction · 0.85

Calls 1

GetMethod · 0.45

Tested by

no test coverage detected