lrs-lang / lib

An experimental standard library
Mozilla Public License 2.0
224 stars 3 forks source link

Improve test debugging #22

Open mahkoh opened 8 years ago

mahkoh commented 8 years ago

Currently, the best way to debug a test is to comment out all other tests and then to set follow-fork-mode child in gdb. This can be done better.

mahkoh commented 8 years ago

It's now possible to run make gdb which will set gdb up to follow the child. You can also pass arguments to the executable and it will then only run those tests that start with one of the arguments. For example

r vec

Will run all tests in the vec module.

r vec::drain

Will only run the vec::drain test.

mahkoh commented 8 years ago

But note that you can only debug one test at a time in gdb because it always follow the first child process.