mirror of
https://github.com/servo/servo.git
synced 2025-07-25 16:20:36 +01:00
Minimal changes to get WPT tests running on Windows.
This commit is contained in:
parent
b2549bb6c4
commit
f78dc9f613
2 changed files with 9 additions and 2 deletions
|
@ -7,6 +7,7 @@ import collections
|
||||||
import os
|
import os
|
||||||
import sys
|
import sys
|
||||||
import subprocess
|
import subprocess
|
||||||
|
import platform
|
||||||
|
|
||||||
DEFAULT_MOVE_UP_CODE = u"\x1b[A"
|
DEFAULT_MOVE_UP_CODE = u"\x1b[A"
|
||||||
DEFAULT_CLEAR_EOL_CODE = u"\x1b[K"
|
DEFAULT_CLEAR_EOL_CODE = u"\x1b[K"
|
||||||
|
@ -29,8 +30,12 @@ class GroupingFormatter(base.BaseFormatter):
|
||||||
|
|
||||||
# TODO(mrobinson, 8313): We need to add support for Windows terminals here.
|
# TODO(mrobinson, 8313): We need to add support for Windows terminals here.
|
||||||
if self.interactive:
|
if self.interactive:
|
||||||
self.line_width = int(subprocess.check_output(['stty', 'size']).split()[1])
|
|
||||||
self.move_up, self.clear_eol = self.get_move_up_and_clear_eol_codes()
|
self.move_up, self.clear_eol = self.get_move_up_and_clear_eol_codes()
|
||||||
|
if platform.system() != "Windows":
|
||||||
|
self.line_width = int(subprocess.check_output(['stty', 'size']).split()[1])
|
||||||
|
else:
|
||||||
|
# Until we figure out proper Windows support, this makes things work well enough to run.
|
||||||
|
self.line_width = 80
|
||||||
|
|
||||||
self.expected = {
|
self.expected = {
|
||||||
'OK': 0,
|
'OK': 0,
|
||||||
|
|
|
@ -256,8 +256,10 @@ def exe_path(name):
|
||||||
return
|
return
|
||||||
|
|
||||||
path = find_executable(name)
|
path = find_executable(name)
|
||||||
if os.access(path, os.X_OK):
|
if path and os.access(path, os.X_OK):
|
||||||
return path
|
return path
|
||||||
|
else:
|
||||||
|
return None
|
||||||
|
|
||||||
|
|
||||||
def check_args(kwargs):
|
def check_args(kwargs):
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue