Fix problems with the --log-to-stdout mode.
Fix problems with the --log-to-stdout mode.

* build/run_tests.py
  (_run_test): If logging to stdout rather than to a file, it previously
    printed the colour-coded "success" or "FAILURE" indications that are
    only intended to be shown in log-to-file mode; and it did so wrongly,
    printing "success" on certain failures (those with exit code != 1).
    Fix all this, and rearrange the message printing code for clarity.


git-svn-id: f8a4e5e023278da1e04e203c7fe051e3c4285d88@880053 13f79535-47bb-0310-9956-ffa450edef68

YueLinHo/Subversion,YueLinHo/Subversion,wbond/subversion,YueLinHo/Subversion,wbond/subversion,wbond/subversion,YueLinHo/Subversion,YueLinHo/Subversion,YueLinHo/Subversion,wbond/subversion,YueLinHo/Subversion,wbond/subversion,wbond/subversion,wbond/subversion,YueLinHo/Subversion