feature: add an option to send bytes with ws#1828
feature: add an option to send bytes with ws#1828YoniGang wants to merge 1 commit intoartilleryio:mainfrom
Conversation
|
I uploaded it without automatic tests. Just tested it myself. We use it in my work to test out web sockets. I would be glad to get some help with tests. |
|
|
||
| const get_bytes_payload = (payload) => { | ||
| if (typeof payload === 'string') { | ||
| let utf8Encode = new TextEncoder() |
There was a problem hiding this comment.
Is there a particular reason to use TextEncoder here? is that a common way to encode binary data for WebSockets?
There was a problem hiding this comment.
Actually not. It was just a way that I found to turn string into bytes with js. I wanted that there will be an option to send string as bytes as well.
|
thank you @YoniGang! adding a test should be fairly straightforward, I'll try to put a quick one together today that we can iterate on if needed. |
|
Hii @hassy! Oo you have any update? |
|
Any update here? I'm hoping to be able to send (and receive/discard) binary payloads over websockets with Artillery |
Add an option to send bytes through web sockets.
Including an example of a function that sends stream and example of how to send bytes with a string without a function
Issue ref: #1780