Mercurial > hg
diff mercurial/help.py @ 32907:bd77ac2bd23a
run-tests: explicitly flush test runner output for Windows stability
When hghave testing goes awry, the output order was changing on Windows.
diff --git a/tests/test-run-tests.t b/tests/test-run-tests.t
--- a/tests/test-run-tests.t
+++ b/tests/test-run-tests.t
@@ -920,10 +920,10 @@
> EOF
> done
$ rt -j 2
- ....
+ ....skipped: unknown feature: notarealhghavefeature\r (esc)
+
+
# Ran 5 tests, 0 skipped, 0 warned, 0 failed.
- skipped: unknown feature: notarealhghavefeature
-
$ cd ..
$ rm -rf broken
Since 'skipped: unknown feature: notarealhghavefeature\n\n' is printed to stdout
and the rest to stderr, it seems like maybe stdio isn't line buffered on
Windows. When a program exits, stdout is flushed before stderr[1].
[1] https://blogs.msdn.microsoft.com/oldnewthing/20060519-09/?p=31133
author | Matt Harbison <matt_harbison@yahoo.com> |
---|---|
date | Sun, 18 Jun 2017 22:19:54 -0400 |
parents | d110fb58424c |
children | 0407a51b9d8c |