Skip to content

Commit a67d37d

Browse files
cclaussBethGriggs
authored andcommitted
test: prepare test/pseudo-tty/testcfg.py Python 3
PR-URL: #24887 Reviewed-By: Rich Trott <rtrott@gmail.com> Reviewed-By: Daniel Bevenius <daniel.bevenius@gmail.com>
1 parent 5cbc0db commit a67d37d

1 file changed

Lines changed: 7 additions & 1 deletion

File tree

‎test/pseudo-tty/testcfg.py‎

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
from __future__ importprint_function
21
# Copyright 2008 the V8 project authors. All rights reserved.
32
# Redistribution and use in source and binary forms, with or without
43
# modification, are permitted provided that the following conditions are
@@ -26,12 +25,19 @@
2625
# (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
2726
# OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
2827

28+
from __future__ importprint_function
29+
2930
importtest
3031
importos
3132
fromos.pathimportjoin, exists, basename, isdir
3233
importre
3334
importutils
3435

36+
try:
37+
reduce# Python 2
38+
exceptNameError: # Python 3
39+
fromfunctoolsimportreduce
40+
3541
try:
3642
xrange# Python 2
3743
exceptNameError:

0 commit comments

Comments
 (0)