Fix GRADLE-2687 Allow to completely suppress stdout and stderr in Tooling API
GRADLE-2687 Suppress output to System.out/err.

Some tweak and make the test pass.
Merge branch 'toolingapi-outputs'