MCPcopy
hub / github.com/seaweedfs/seaweedfs / recordingSender

Struct recordingSender

weed/worker/tasks/s3_lifecycle/handler_test.go:23–30  ·  view source on GitHub ↗

Tests cover the worker-handler surface that runs without a live filer or S3 server: pure helpers (clusterS3Endpoints, readString), Capability/Descriptor sanity, and the Detect input-validation / skip-activity / proposal paths driven by a recorder sender. recordingSender captures everything the handl

Source from the content-addressed store, hash-verified

21// recordingSender captures everything the handler sends so each Detect
22// case can assert on activities, proposals, and completion.
23type recordingSender struct {
24 proposals []*plugin_pb.DetectionProposals
25 completes []*plugin_pb.DetectionComplete
26 activities []*plugin_pb.ActivityEvent
27 // errOn forces the named send to fail; lets tests cover the
28 // SendComplete error-propagation path without a full transport stub.
29 errOn map[string]error
30}
31
32func (r *recordingSender) SendProposals(p *plugin_pb.DetectionProposals) error {
33 if err := r.errOn["proposals"]; err != nil {

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected