diff options
author | Jukka Jylänki <jujjyl@gmail.com> | 2013-11-13 19:16:24 +0200 |
---|---|---|
committer | Jukka Jylänki <jujjyl@gmail.com> | 2013-11-13 19:16:50 +0200 |
commit | 0286c6739d67bcbe5f0f10f1fd2a0a6debce33d1 (patch) | |
tree | 202c7181136e6d04183ee520fe0140738419aef0 | |
parent | c9bdd33a113b4236c60b61abaec4e5e8a8b89028 (diff) |
Write src.cpp in unit test in binary mode so that line endings are stored as '\n' on Windows as well. Fixes test other.test_fs_stream_proto on Windows, where the test assert()s on the binary file size of the written src.cpp (Windows '\r\n' line endings would bloat the size slightly, causing test failure).
-rw-r--r-- | tests/test_other.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/test_other.py b/tests/test_other.py index 3a781042..fafa6d33 100644 --- a/tests/test_other.py +++ b/tests/test_other.py @@ -2016,7 +2016,7 @@ FWakaGLXFleeflsMarfoo::FWakaGLXFleeflsMarfoo(unsigned int, unsigned int, unsigne try_delete(path_from_root('tests', 'Module-exports', 'test.js.map')) def test_fs_stream_proto(self): - open('src.cpp', 'w').write(r''' + open('src.cpp', 'wb').write(r''' #include <stdio.h> #include <fcntl.h> #include <unistd.h> |