switch to http API.
This commit is contained in:
parent
502e104e6a
commit
0e2d06fc39
@ -439,7 +439,7 @@ func (n *Ensemble) Start() *Ensemble {
|
|||||||
|
|
||||||
node.MockHost(n.mn),
|
node.MockHost(n.mn),
|
||||||
|
|
||||||
node.Override(new(v1api.FullNode), m.FullNode),
|
node.Override(new(v1api.FullNode), m.FullNode.FullNode),
|
||||||
node.Override(new(*lotusminer.Miner), lotusminer.NewTestMiner(mineBlock, m.ActorAddr)),
|
node.Override(new(*lotusminer.Miner), lotusminer.NewTestMiner(mineBlock, m.ActorAddr)),
|
||||||
|
|
||||||
// disable resource filtering so that local worker gets assigned tasks
|
// disable resource filtering so that local worker gets assigned tasks
|
||||||
|
@ -30,7 +30,7 @@ func fullRpc(t *testing.T, f *TestFullNode) *TestFullNode {
|
|||||||
|
|
||||||
srv, maddr := CreateRPCServer(t, handler)
|
srv, maddr := CreateRPCServer(t, handler)
|
||||||
|
|
||||||
cl, stop, err := client.NewFullNodeRPCV1(context.Background(), "ws://"+srv.Listener.Addr().String()+"/rpc/v1", nil)
|
cl, stop, err := client.NewFullNodeRPCV1(context.Background(), "http://"+srv.Listener.Addr().String()+"/rpc/v1", nil)
|
||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
t.Cleanup(stop)
|
t.Cleanup(stop)
|
||||||
f.ListenAddr, f.FullNode = maddr, cl
|
f.ListenAddr, f.FullNode = maddr, cl
|
||||||
@ -44,7 +44,7 @@ func minerRpc(t *testing.T, m *TestMiner) *TestMiner {
|
|||||||
|
|
||||||
srv, maddr := CreateRPCServer(t, handler)
|
srv, maddr := CreateRPCServer(t, handler)
|
||||||
|
|
||||||
cl, stop, err := client.NewStorageMinerRPCV0(context.Background(), "ws://"+srv.Listener.Addr().String()+"/rpc/v0", nil)
|
cl, stop, err := client.NewStorageMinerRPCV0(context.Background(), "http://"+srv.Listener.Addr().String()+"/rpc/v0", nil)
|
||||||
require.NoError(t, err)
|
require.NoError(t, err)
|
||||||
t.Cleanup(stop)
|
t.Cleanup(stop)
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user