It does not allow stepping. If you're not sure what code path a test scenario is triggering, pry won't help you, you have to litter inspect statements everywhere
On Tuesday, March 27, 2018 at 2:47:26 PM UTC-6, OvermindDL1 wrote: > > Doesn't `IEX.pry` work well for that? You can even gate it behind a > configuration variable or so too. > > On Saturday, March 24, 2018 at 6:29:54 AM UTC-6, Adam Kirk wrote: >> >> Ok so this is just an idea and it might be ignorant: >> >> What is `iex` had a `—debug` option that could be: >> >> 1) called with no value and by default elixir would find all `debugger` >> statements in your code, strip them out and set breakpoints on them. Maybe >> `debugger(3)` would skip 3 times >> >> 2) allow `—debug=file.ex:45` to set a breakpoint >> >> 3) maybe also a `—gui` option too? >> >> The reason is, I write tests to debug things. I write a test that >> reproduces a problem and then I get the test to pass. Then it’ll never >> regress. But I’m stuck with IO.inspect and IEx.pry because Its not obvious >> how to use the step debugger when starting with `iex -S mix test` >> >> Iex.pry is fine for stopping and looking around and trying things in >> context, so we’re half way there, but being able to just as easily step >> through code so i dont have to litter io.inspect everywhere would be so >> awesome. >> >> One of the main reasons I’d love this is that while it requires me to >> edit my source, putting debugger where i want to stop is sooooooooo much >> easier than the setup work currently required (type file and line number or >> entire module and function name) >> >> A debugger statement is so super easy to remember and use and people are >> familiar with it from ruby and javascript. It is the number one thing by >> far I miss from Ruby. > > -- You received this message because you are subscribed to the Google Groups "elixir-lang-core" group. To unsubscribe from this group and stop receiving emails from it, send an email to elixir-lang-core+unsubscr...@googlegroups.com. To view this discussion on the web visit https://groups.google.com/d/msgid/elixir-lang-core/548790dc-e3ac-4dbc-958f-30a2f1991d84%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.