mirror of
https://github.com/ipfs/kubo.git
synced 2025-07-02 03:28:25 +08:00
test(bitswap) Close (but skip for now)
License: MIT Signed-off-by: Brian Tiger Chow <brian@perfmode.com>
This commit is contained in:
@ -18,6 +18,21 @@ import (
|
||||
mock "github.com/jbenet/go-ipfs/routing/mock"
|
||||
)
|
||||
|
||||
func TestClose(t *testing.T) {
|
||||
// TODO
|
||||
t.Skip("TODO Bitswap's Close implementation is a WIP")
|
||||
vnet := tn.VirtualNetwork()
|
||||
rout := mock.VirtualRoutingServer()
|
||||
sesgen := NewSessionGenerator(vnet, rout)
|
||||
bgen := NewBlockGenerator()
|
||||
|
||||
block := bgen.Next()
|
||||
bitswap := sesgen.Next()
|
||||
|
||||
bitswap.exchange.Close()
|
||||
bitswap.exchange.GetBlock(context.Background(), block.Key())
|
||||
}
|
||||
|
||||
func TestGetBlockTimeout(t *testing.T) {
|
||||
|
||||
net := tn.VirtualNetwork()
|
||||
|
Reference in New Issue
Block a user