Documentation
¶
Overview ¶
Package objectstore provides deterministic test doubles for AppTheory object-store code.
Index ¶
- type Call
- type FakeStore
- func (s *FakeStore) Calls() []Call
- func (s *FakeStore) Delete(_ context.Context, input store.DeleteInput) error
- func (s *FakeStore) Get(_ context.Context, input store.GetInput) (*store.GetOutput, error)
- func (s *FakeStore) Put(_ context.Context, input store.PutInput) (store.ObjectRef, error)
- func (s *FakeStore) SetError(operation Operation, err error)
- type Operation
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Call ¶
type Call struct {
Operation Operation
Ref store.ObjectRef
MaxBytes int64
ContentType string
Metadata map[string]string
Payload []byte
}
Call is one recorded FakeStore operation.
type FakeStore ¶
type FakeStore struct {
// contains filtered or unexported fields
}
FakeStore is an in-memory Store for tests.
FakeStore records calls in order, injects per-operation failures, and copies all byte slices and metadata maps at its boundary.
func (*FakeStore) Delete ¶
Delete removes the referenced object. An unversioned ref removes all versions for the bucket/key.
Click to show internal directories.
Click to hide internal directories.