Documentation ¶
Index ¶
- func GenerateCids(n int) []cid.Cid
- func GetBstoreLen(ctx context.Context, t *testing.T, bs RoBlockstore) int
- func OpenSampleCar(t *testing.T, carFileName string) *blockstore.ReadOnly
- func RandomCids(n int) ([]cid.Cid, error)
- func RandomMultihashes(n int) ([]multihash.Multihash, error)
- func SetupDataTransferOnHost(t *testing.T, h host.Host, store datastore.Batching, lsys ipld.LinkSystem) datatransfer.Manager
- func ThisDir(t *testing.T) string
- type RoBlockstore
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func GetBstoreLen ¶
GetBstoreLen gets the total CID cound in a blockstore
func OpenSampleCar ¶
func OpenSampleCar(t *testing.T, carFileName string) *blockstore.ReadOnly
OpenSampleCar opens a car file in the testdata directory to a blockstore
func RandomCids ¶ added in v0.2.0
func RandomMultihashes ¶ added in v0.2.0
func SetupDataTransferOnHost ¶
func SetupDataTransferOnHost(t *testing.T, h host.Host, store datastore.Batching, lsys ipld.LinkSystem) datatransfer.Manager
SetupDataTransferOnHost generates a data transfer instance for the given libp2p host
Types ¶
type RoBlockstore ¶
RoBlockstore is just the needed interface for GetBstoreLen
Click to show internal directories.
Click to hide internal directories.