From bb40a106aa7ebdf4b713669e679ca4ba97e60d90 Mon Sep 17 00:00:00 2001 From: Martin Holst Swende Date: Fri, 10 Nov 2023 13:17:36 +0100 Subject: [PATCH] Update rpc/subscription_test.go --- rpc/subscription_test.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rpc/subscription_test.go b/rpc/subscription_test.go index 410fe4978d..3a131c8e6b 100644 --- a/rpc/subscription_test.go +++ b/rpc/subscription_test.go @@ -272,7 +272,7 @@ func TestNotify(t *testing.T) { Number: big.NewInt(100), } notifier.Notify(id, msg) - have := strings.TrimSpace(string(out.Bytes())) + have := strings.TrimSpace(out.String()) want := `{"jsonrpc":"2.0","method":"_subscription","params":{"subscription":"test","result":{"parentHash":"0x0000000000000000000000000000000000000000000000000000000000000001","sha3Uncles":"0x0000000000000000000000000000000000000000000000000000000000000000","miner":"0x0000000000000000000000000000000000000000","stateRoot":"0x0000000000000000000000000000000000000000000000000000000000000000","transactionsRoot":"0x0000000000000000000000000000000000000000000000000000000000000000","receiptsRoot":"0x0000000000000000000000000000000000000000000000000000000000000000","logsBloom":"0x00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000","difficulty":null,"number":"0x64","gasLimit":"0x0","gasUsed":"0x0","timestamp":"0x0","extraData":"0x","mixHash":"0x0000000000000000000000000000000000000000000000000000000000000000","nonce":"0x0000000000000000","baseFeePerGas":null,"withdrawalsRoot":null,"blobGasUsed":null,"excessBlobGas":null,"parentBeaconBlockRoot":null,"hash":"0xe5fb877dde471b45b9742bb4bb4b3d74a761e2fb7cb849a3d2b687eed90fb604"}}}` if have != want { t.Errorf("have:\n%v\nwant:\n%v\n", have, want)