tests: prevent printing \r to stdout
Like we've done in other recent commits, we need to change
sys.stdout on Python 3 to not use os.linesep so output is
consistent on Python 3 on Windows.
With this change, test-notify.t now passes on Python 3 on Windows!
Differential Revision: https://phab.mercurial-scm.org/D8342
To run the tests, do:
cd tests/
python run-tests.py
See https://mercurial-scm.org/wiki/WritingTests for
more information on writing tests.