File tree Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Expand file tree Collapse file tree 1 file changed +6
-4
lines changed Original file line number Diff line number Diff line change @@ -270,11 +270,13 @@ async def test_listen_event_awaits_msg_processing_when_subscription_queue_is_ful
270
270
sub_request_information = RequestInformation (
271
271
method = RPCEndpoint ("eth_subscribe" ),
272
272
params = ["mock" ],
273
- response_formatters = () ,
273
+ response_formatters = [[], [], []] ,
274
274
subscription_id = sub_id ,
275
275
)
276
276
async_w3 .provider ._request_processor ._request_information_cache .cache (
277
- "" , sub_request_information
277
+ # cache key is the result of `generate_cache_key` with the sub_id as the arg
278
+ "0138b5d63d66121d8a6e680d23720fa7" ,
279
+ sub_request_information ,
278
280
)
279
281
280
282
mocked_sub = {
@@ -305,8 +307,8 @@ async def test_listen_event_awaits_msg_processing_when_subscription_queue_is_ful
305
307
async_w3 .provider ._listen_event .set .assert_not_called ()
306
308
307
309
async for message in async_w3 .socket .process_subscriptions ():
308
- # assert the very next message is the mocked subscription
309
- assert message == mocked_sub
310
+ # assert the very next message is the formatted mocked subscription
311
+ assert message == mocked_sub [ "params" ]
310
312
break
311
313
312
314
# assert we set the _listen_event after we consume the message
You can’t perform that action at this time.
0 commit comments