py3: replace file() with open() in test-contrib.t
authorPulkit Goyal <7895pulkit@gmail.com>
Sun, 11 Feb 2018 17:19:07 +0530
changeset 36031 acda1977210c
parent 36030 b85b0bbed6de
child 36032 f91b7f26c68a
py3: replace file() with open() in test-contrib.t file() is not present in Python 3. Differential Revision: https://phab.mercurial-scm.org/D2134
tests/test-contrib.t
--- a/tests/test-contrib.t	Sun Feb 11 17:14:00 2018 +0530
+++ b/tests/test-contrib.t	Sun Feb 11 17:19:07 2018 +0530
@@ -201,7 +201,7 @@
 
 binary file
 
-  $ $PYTHON -c "f = file('binary-local', 'w'); f.write('\x00'); f.close()"
+  $ $PYTHON -c "f = open('binary-local', 'w'); f.write('\x00'); f.close()"
   $ cat orig >> binary-local
   $ $PYTHON simplemerge -p binary-local base other
   warning: binary-local looks like a binary file.