javascriptnode.jsload-testingk6

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.


Solution

  • 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.