From 0f0d97285759bf5a058ddf9c57bbd15ab6996e9c Mon Sep 17 00:00:00 2001 From: Mohammad Kermani Date: Wed, 26 Jun 2024 11:13:27 +0000 Subject: [PATCH] test(scaling-large-messages): hide debug logs The message is quite large, making it hard to read the logs in debug mode. --- tests/scaling-large-messages/src/node/node.ts | 9 +++++++-- 1 file changed, 7 insertions(+), 2 deletions(-) diff --git a/tests/scaling-large-messages/src/node/node.ts b/tests/scaling-large-messages/src/node/node.ts index 7ea8d4b..2d2edae 100644 --- a/tests/scaling-large-messages/src/node/node.ts +++ b/tests/scaling-large-messages/src/node/node.ts @@ -1,7 +1,10 @@ import { createRoseNetNode } from '@rosen-bridge/rosenet-node'; const node = await createRoseNetNode({ - logger: console, + logger: { + ...console, + debug: () => {}, + }, relayMultiaddrs: [process.env.RELAY_MULTIADDR!], privateKey: process.env.PRIVATE_KEY!, }); @@ -51,7 +54,9 @@ setTimeout(async () => { }, 10_000); }, 30_000); -node.handleIncomingMessage(async () => {}); +node.handleIncomingMessage(async (_, message) => { + console.info(`Large message received, length: ${message?.length}`); +}); node.subscribe('rosenet-news', (message) => { console.info(