aboutsummaryrefslogtreecommitdiffstats
path: root/python/servo
diff options
context:
space:
mode:
authormarmeladema <xademax@gmail.com>2019-12-10 23:51:49 +0000
committermarmeladema <xademax@gmail.com>2019-12-11 13:57:07 +0000
commit9d04f231f4a32050d78221d4e13d4951df649269 (patch)
treec5aee5ba6540247e74d2a35d8a10c1a2018bf166 /python/servo
parent8d4cedb9117f66691e553bdca8116f18ff1283de (diff)
downloadservo-9d04f231f4a32050d78221d4e13d4951df649269.tar.gz
servo-9d04f231f4a32050d78221d4e13d4951df649269.zip
Make `mach test-tidy --no-wpt` compatible with Python3
Note: tidiness tests of Python file using flake8 was effectively broken since a previous commit for Python3 compatibility
Diffstat (limited to 'python/servo')
-rw-r--r--python/servo/testing_commands.py4
1 files changed, 2 insertions, 2 deletions
diff --git a/python/servo/testing_commands.py b/python/servo/testing_commands.py
index f44bfd46f53..56a81baabff 100644
--- a/python/servo/testing_commands.py
+++ b/python/servo/testing_commands.py
@@ -776,7 +776,7 @@ class MachCommands(CommandBase):
def setup_clangfmt(env):
cmd = "clang-format.exe" if sys.platform == "win32" else "clang-format"
try:
- version = check_output([cmd, "--version"], env=env).rstrip()
+ version = check_output([cmd, "--version"], env=env, universal_newlines=True).rstrip()
print(version)
if not version.startswith("clang-format version {}.".format(CLANGFMT_VERSION)):
print("clang-format: wrong version (v{} required). Skipping CPP formatting.".format(CLANGFMT_VERSION))
@@ -785,7 +785,7 @@ def setup_clangfmt(env):
print("clang-format not installed. Skipping CPP formatting.")
return False, None, None
gitcmd = ['git', 'ls-files']
- gitfiles = check_output(gitcmd + CLANGFMT_CPP_DIRS).splitlines()
+ gitfiles = check_output(gitcmd + CLANGFMT_CPP_DIRS, universal_newlines=True).splitlines()
filtered = [line for line in gitfiles if line.endswith(".h") or line.endswith(".cpp")]
return True, cmd, filtered