[runtests] flush outputs after test is done

Change-Id: Ie3dcd177bd2db782ee8ae44d2e0e1c824f9d2ba2
diff --git a/zircon/system/ulib/runtests-utils/fuchsia-run-test.cpp b/zircon/system/ulib/runtests-utils/fuchsia-run-test.cpp
index 5d25612..b689f79 100644
--- a/zircon/system/ulib/runtests-utils/fuchsia-run-test.cpp
+++ b/zircon/system/ulib/runtests-utils/fuchsia-run-test.cpp
@@ -329,6 +329,9 @@
             fwrite(buf, 1, bytes_read, output_file);
             fwrite(buf, 1, bytes_read, stdout);
         }
+        fflush(stdout);
+        fflush(stderr);
+        fflush(output_file);
         if (fclose(output_file)) {
             fprintf(stderr, "FAILURE:  Could not close %s: %s", output_filename,
                     strerror(errno));