From b5c12b9f4d2c32a5013c340f7e40649cb5f2b41a Mon Sep 17 00:00:00 2001 From: cclauss Date: Sun, 30 Dec 2018 13:07:28 +0100 Subject: [PATCH] print() is a function in Python 3 (#1520) --- test/subset/generate-expected-outputs.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/test/subset/generate-expected-outputs.py b/test/subset/generate-expected-outputs.py index 9ebf082f6..6d11cbfe6 100755 --- a/test/subset/generate-expected-outputs.py +++ b/test/subset/generate-expected-outputs.py @@ -3,6 +3,8 @@ # Pre-generates the expected output subset files (via fonttools) for # specified subset test suite(s). +from __future__ import print_function, division, absolute_import + import io import os import sys @@ -12,7 +14,7 @@ from subset_test_suite import SubsetTestSuite def usage(): - print "Usage: generate-expected-outputs.py ..." + print("Usage: generate-expected-outputs.py ...") def generate_expected_output(input_file, unicodes, profile_flags, output_path): @@ -37,11 +39,11 @@ for path in args: test_suite = SubsetTestSuite(path, f.read()) output_directory = test_suite.get_output_directory() - print "Generating output files for %s" % output_directory + print("Generating output files for %s" % output_directory) for test in test_suite.tests(): unicodes = test.unicodes() font_name = test.get_font_name() - print "Creating subset %s/%s" % (output_directory, font_name) + print("Creating subset %s/%s" % (output_directory, font_name)) generate_expected_output(test.font_path, unicodes, test.get_profile_flags(), os.path.join(output_directory, font_name))