Fix ./Build test in debug builds.

When writing to a pipe, stdout is block-buffered rather than line-buffered,
so it needs an explicit flush to avoid garbling test output.