Repository: incubator-beam Updated Branches: refs/heads/python-sdk 99a33ecdb -> 6b0614564
Fixes a bug in avroio_test.py on Windows. We open a binary file without 'b' mode. Without this file can get corrupted in Windows and the test becomes flaky. Project: http://git-wip-us.apache.org/repos/asf/incubator-beam/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-beam/commit/d894125f Tree: http://git-wip-us.apache.org/repos/asf/incubator-beam/tree/d894125f Diff: http://git-wip-us.apache.org/repos/asf/incubator-beam/diff/d894125f Branch: refs/heads/python-sdk Commit: d894125ff2b8d53babcffb7704986dad4df825b6 Parents: 99a33ec Author: Chamikara Jayalath <[email protected]> Authored: Wed Oct 5 16:23:09 2016 -0700 Committer: Robert Bradshaw <[email protected]> Committed: Thu Oct 6 13:01:05 2016 -0700 ---------------------------------------------------------------------- sdks/python/apache_beam/io/avroio_test.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-beam/blob/d894125f/sdks/python/apache_beam/io/avroio_test.py ---------------------------------------------------------------------- diff --git a/sdks/python/apache_beam/io/avroio_test.py b/sdks/python/apache_beam/io/avroio_test.py index dbaf6f3..697bd2c 100644 --- a/sdks/python/apache_beam/io/avroio_test.py +++ b/sdks/python/apache_beam/io/avroio_test.py @@ -213,7 +213,7 @@ class TestAvro(unittest.TestCase): def test_corrupted_file(self): file_name = self._write_data() - with open(file_name, 'r') as f: + with open(file_name, 'rb') as f: data = bytearray(f.read()) # Corrupt the last character of the file which is also the last character of
