Sorry for the confusion. I did misread the question. Seems Mix.Shell.Process is exactly what you need:
This is mainly useful in tests, allowing us to assert if given messages were received or not instead of performing checks on some captured IO. Since we need to guarantee a clean slate between tests, there is also a
flush/1function responsible for flushing all:mix_shellrelated messages from the process inbox.
It’s not Hex-specific at all.






















