That did the job, thanks José.  I'd already tried using ExUnit.CaptureIO to 
no effect, didn't know this tag existed.

Louis, in case you'd still like to know, this was the log output:

07:43:21.560 [error] GenServer #PID<0.99.0> terminating
** (stop) "Closing connection"
Last message: {.. bunch of stuff ..}
State: {%{connection_abort: #Function<3.107869130/1 in 
ZeroMQ.ConnectionTest.__ex_unit_setup_0/1>, message_delivery: 
#Function<1.107869130/1 in ZeroMQ.ConnectionTest.__ex_unit_setup_0/1>, 
peer_delivery: #Function<2.107869130/1 in 
ZeroMQ.ConnectionTest.__ex_unit_setup_0/1>, security_mechanism: 
#Function<5.107869130/1 in ZeroMQ.ConnectionTest.__ex_unit_setup_0/1>}, 
#PID<0.100.0>, {.. closing state ..}}

Thanks both,
Elliot

On Monday, May 23, 2016 at 8:18:34 PM UTC+1, José Valim wrote:
>
> Just use the capture log tag to, well, capture the log:
>
> @tag :capture_log
> test "this test will log error stuff" do
>
>
> You can also set it for the whole suite: ExUnit.start(capture_log: true). 
> If you do so, the log will still be included in error reports.
>
>
>
>
> *José Valim*
> www.plataformatec.com.br
> Skype: jv.ptec
> Founder and Director of R&D
>
> On Mon, May 23, 2016 at 9:08 PM, Louis Pilfold <[email protected] 
> <javascript:>> wrote:
>
>> Hey Elliot
>>
>> Could you share the printed notification with us please?
>>
>> Cheers,
>> Louis
>>
>> On 23 May 2016 at 19:01, Elliot Crosby-McCullough <[email protected] 
>> <javascript:>> wrote:
>> > Hello!
>> >
>> > I'm testing some GenServers, specifically testing certain behaviours 
>> that
>> > deliberately cause the GenServer to terminate itself.
>> >
>> > This is all going well, except the test run outputs a notification 
>> about the
>> > closing process (the GenServer, not the test process) on what I assume 
>> is
>> > STDERR.  Is there some way to suppress this?
>> >
>> > It seems to happen whether I start the genserver via `start_link` and 
>> unlink
>> > it or create one without linking.
>> >
>> > All the best,
>> > Elliot
>> >
>> > --
>> > You received this message because you are subscribed to the Google 
>> Groups
>> > "elixir-lang-talk" group.
>> > To unsubscribe from this group and stop receiving emails from it, send 
>> an
>> > email to [email protected] <javascript:>.
>> > To view this discussion on the web visit
>> > 
>> https://groups.google.com/d/msgid/elixir-lang-talk/CAD2T2cju977Dm8rC_dgfDaTHacOSGvhryXwgmUZZn1k5vADPww%40mail.gmail.com
>> .
>> > For more options, visit https://groups.google.com/d/optout.
>>
>> --
>> You received this message because you are subscribed to the Google Groups 
>> "elixir-lang-talk" group.
>> To unsubscribe from this group and stop receiving emails from it, send an 
>> email to [email protected] <javascript:>.
>> To view this discussion on the web visit 
>> https://groups.google.com/d/msgid/elixir-lang-talk/CAM-pwt4QmpR0gy_PxnDJ_nxOHUNurquNxNTEpyYVuE4Nwd7%2B1g%40mail.gmail.com
>> .
>> For more options, visit https://groups.google.com/d/optout.
>>
>
>

-- 
You received this message because you are subscribed to the Google Groups 
"elixir-lang-talk" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/elixir-lang-talk/1c2b3ff9-3e35-4c2b-bcc1-eac6ebb06970%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to