From 6652dde162597694aceb409dbbb409eeb80f41e2 Mon Sep 17 00:00:00 2001 From: shaojunda Date: Thu, 15 Aug 2024 15:07:57 +0800 Subject: [PATCH] test: GetLiveCell with includedTxPool --- rpc/client_test.go | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/rpc/client_test.go b/rpc/client_test.go index 2c0cf27d..404615d5 100644 --- a/rpc/client_test.go +++ b/rpc/client_test.go @@ -402,6 +402,21 @@ func TestClient_GetLiveCell(t *testing.T) { assert.NotNil(t, cellWithStatus) } +func TestClient_GetLiveCellIncludeTxPool(t *testing.T) { + outPoint := types.OutPoint{ + TxHash: types.HexToHash("0xf8de3bb47d055cdf460d93a2a6e1b05f7432f9777c8c474abf4eec1d4aee5d37"), + Index: 0, + } + + includeTxPool := true + + cellWithStatus, err := testClient.GetLiveCell(ctx, &outPoint, true, &includeTxPool) + if err != nil { + t.Fatal(err) + } + assert.NotNil(t, cellWithStatus) +} + func TestGetTip(t *testing.T) { resp, err := testClient.GetIndexerTip(context.Background()) assert.NoError(t, err)