Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is it possible to attach a debugger to k6 scripts?

I'm hoping to adopt k6 for load testing, but I'm having trouble developing scripts for it. My primary use case is to check at each request to see if I'm receiving the correct headers and content and would like to inspect the response with a debugger.

I tried to run the script on its own by attaching the node inspect debugger (https://nodejs.org/api/debugger.html) but the file doesn't get executed because the import and export module keywords are unrecognized by this current version of node (8.7.0)

I'm also unable to find any documentation on how to debug these scripts.

like image 768
Jason Lee Avatar asked Nov 08 '22 15:11

Jason Lee


1 Answers

There is no debugger support (currently known) for k6 scripting. It's manual debugging at this time.

k6 runs javascript (ECMA6) and has an API documented at http://k6.io

Sidenote: k6 is not node and will not work with node tooling.

like image 127
Michael Sjölin Avatar answered Nov 14 '22 22:11

Michael Sjölin