Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type TestScenario ¶
type TestScenario struct {
L *logrus.Logger
Upstream catalog.Upstream
Publisher *publisher.ContentPublisher
PublisherPrivateKey ed25519.PrivateKey
Catalog catalog.ContentCatalog
Escrow *publisher.Escrow
EscrowID common.EscrowID
Params *TestScenarioParams
Chunks [][]byte
ObjectID common.ObjectID
Caches []*cache.Cache
CacheConfigs []*cache.ConfigFile
}
func GenerateTestScenario ¶
func GenerateTestScenario(l *logrus.Logger, params *TestScenarioParams) (*TestScenario, error)
func (*TestScenario) ChunkCount ¶
func (ts *TestScenario) ChunkCount() uint64
func (*TestScenario) ObjectData ¶
func (ts *TestScenario) ObjectData() []byte
type TestScenarioParams ¶
type TestScenarioParams struct {
ChunkSize uint64
ObjectSize uint64
// MockUpstream indicates whether a mock upstream should be generated in place of the default HTTP upstream. If
// Upstream is non-nil, no upstream is generated, and this value has no effect.
MockUpstream bool
// GenerateObject indicates whether or not a random test object (with path "/foo/bar") should be generated. If
// MockUpstream is also true, the object is inserted into the mock upstream.
GenerateObject bool
// These are optional. If provided, they override the default that would have been generated.
L *logrus.Logger
Upstream catalog.Upstream
PublisherAddr string
}
Click to show internal directories.
Click to hide internal directories.