[RFC] CMake: Capture stderr when running tests.

A possible fix for #1301, based on @Islah's last comment there.
I'd say hide it unless we fail, it is pretty hard to figure which or how the test caused those messages anyway.