Skip to content

redbug does not work in eunit #22

@e-shubin

Description

@e-shubin

A simple eunit test case causes an error in redbug

rb_test() ->
    {_, _} = redbug:start("lists:sort->stack", [{print_file, "redbug.txt"}]),
    timer:sleep(2000),
    ?assertEqual([1,2,3], lists:sort([3,2,1])),
    redbug:stop().
=ERROR REPORT==== 4-Feb-2014::15:04:28 ===
Error in process <0.69.0> with exit value: {terminated,[{io,format,[<0.67.0>,"~s~n",["\n15:04:28 <0.65.0>({erlang,apply,2}) {lists,sort,[[3,2,1]]}"]],[]},{redbug,'-mk_outer/1-fun-2-',5,[{file,"redbug.erl"},{line,343}]},{redbug,'-wrap_print_fun/1-fun-0-',3,[{file,"redbug.erl"},{line... 

I works good if eunit is not used.
I would love to see redbug working in eunit tests.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions