Block Websocket connection

Is there a way in katalon to temporarily block the WebSockets connection in the Chrome browser for some time and unblock it again after the use?
Thanks in advance.

Hi, @kazurayam @Brandon_Hein can you ppl guide here. Thanks.

I believe that there is no katalon-built-in feature that affects WebSockets connection in browsers.

I guess, your web page is equipped with a set of custom JavaScript codes that drives WebSocket connection. Then you should be able to design your code to expose a callable API (JavaScript function) which close/open the connection when you want to.

Provided this sort of API equipped, your Katalon test case would have a chance to invoke that API using WebUI.executeJavaScript

1 Like