You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The README.md gives me the impression that debugging of tests is possible with the --serial option. It looks like this option is designed for debugging ava itself though.
When running this via the node debugger (or node inspector) the breakpoint is not triggered, possibly due to the code transformations via babel.
Since ava spawns new processes, debugging cli.js directly is not possible. The new node processes try to listen to the same debug port and thus crash with EADDRINUSE :::5858. By hacking fork.js and adding options['execArgv'] = ['--debug-brk=5860']; I could attach node inspector to this port but it still failed to trigger my breakpoint within the test.
The README.md gives me the impression that debugging of tests is possible with the --serial option. It looks like this option is designed for debugging ava itself though.
I tried debugging tests in the following way:
ava --initnpm install signal-exitBased on add covenience util for debugging #225, put the following code in
node_modules/ava/debug.jsMake a simple test with a debugger keyword:
node debug node_modules/ava/debug.js " {\"file\":\"path/to/test.js\",\"failFast\":false,\"serial\":true,\"require\":[]} "When running this via the node debugger (or node inspector) the breakpoint is not triggered, possibly due to the code transformations via babel.
Since ava spawns new processes, debugging cli.js directly is not possible. The new node processes try to listen to the same debug port and thus crash with
EADDRINUSE :::5858. By hacking fork.js and addingoptions['execArgv'] = ['--debug-brk=5860'];I could attach node inspector to this port but it still failed to trigger my breakpoint within the test.Is there any way to use a debugger for my tests?