From 347ee5300a48899dd5f623e46f71c3bc2ad17766 Mon Sep 17 00:00:00 2001 From: Oliver Townsend Date: Thu, 27 Jun 2024 11:34:53 -0700 Subject: [PATCH] Update tests --- core/services/ocr2/plugins/liquiditymanager/plugin_test.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/core/services/ocr2/plugins/liquiditymanager/plugin_test.go b/core/services/ocr2/plugins/liquiditymanager/plugin_test.go index cb3af9d08f..90727270f7 100644 --- a/core/services/ocr2/plugins/liquiditymanager/plugin_test.go +++ b/core/services/ocr2/plugins/liquiditymanager/plugin_test.go @@ -289,7 +289,7 @@ func TestPlugin_Observation(t *testing.T) { for sourceDest, bridgeFn := range tc.bridges { br, err2 := bridgeFn(t) p.bridgeFactory. - On("NewBridge", sourceDest[0], sourceDest[1]). + On("NewBridge", ctx, sourceDest[0], sourceDest[1]). Return(br, err2) } @@ -660,7 +660,7 @@ func TestPlugin_Outcome(t *testing.T) { for sourceDest, bridgeFn := range tc.bridges { br, err := bridgeFn(t) p.bridgeFactory. - On("NewBridge", sourceDest[0], sourceDest[1]). + On("NewBridge", mock.Anything /* cancelContext */, sourceDest[0], sourceDest[1]). Return(br, err) } @@ -1135,7 +1135,7 @@ func TestPlugin_E2EWithMocks(t *testing.T) { for _, edge := range edges { br, ok := n.bridges[[2]models.NetworkSelector{edge.Source, edge.Dest}] require.True(t, ok, "the test case is wrong, bridge is not defined %d->%d", edge.Source, edge.Dest) - n.bridgeFactory.On("NewBridge", edge.Source, edge.Dest).Return(br, nil).Maybe() + n.bridgeFactory.On("NewBridge", mock.Anything /* cancelContext */, edge.Source, edge.Dest).Return(br, nil).Maybe() pendingTransfers := make([]models.PendingTransfer, 0) for _, tr := range round.pendingTransfersPerNode[i] {