mirror of
https://github.com/servo/servo.git
synced 2025-08-04 13:10:20 +01:00
wpt-tests-to-run -> wpt-args and make them last so they can override already provide (#33115)
d options Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com>
This commit is contained in:
parent
84b5b64424
commit
b5fe99ba5d
8 changed files with 32 additions and 31 deletions
|
@ -56,10 +56,10 @@ class JobConfig(object):
|
|||
wpt_layout: Layout = Layout.none
|
||||
profile: str = "release"
|
||||
unit_tests: bool = False
|
||||
wpt_tests_to_run: str = ""
|
||||
wpt_args: str = ""
|
||||
# These are the fields that must match in between two JobConfigs for them to be able to be
|
||||
# merged. If you modify any of the fields above, make sure to update this line as well.
|
||||
merge_compatibility_fields: ClassVar[List[str]] = ['workflow', 'profile', 'wpt_tests_to_run']
|
||||
merge_compatibility_fields: ClassVar[List[str]] = ['workflow', 'profile', 'wpt_args']
|
||||
|
||||
def merge(self, other: JobConfig) -> bool:
|
||||
"""Try to merge another job with this job. Returns True if merging is successful
|
||||
|
@ -101,7 +101,7 @@ def handle_preset(s: str) -> Optional[JobConfig]:
|
|||
elif s == "webgpu":
|
||||
return JobConfig("WebGPU CTS", Workflow.LINUX,
|
||||
wpt_layout=Layout.layout2020, # reftests are mode for new layout
|
||||
wpt_tests_to_run="_webgpu", # run only webgpu cts
|
||||
wpt_args="_webgpu", # run only webgpu cts
|
||||
profile="production", # WebGPU works to slow with debug assert
|
||||
unit_tests=False) # production profile does not work with unit-tests
|
||||
else:
|
||||
|
@ -176,7 +176,7 @@ class TestParser(unittest.TestCase):
|
|||
'unit_tests': True,
|
||||
'workflow': 'linux',
|
||||
'wpt_layout': 'none',
|
||||
'wpt_tests_to_run': ''
|
||||
'wpt_args': ''
|
||||
}]
|
||||
})
|
||||
|
||||
|
@ -189,7 +189,7 @@ class TestParser(unittest.TestCase):
|
|||
"wpt_layout": "all",
|
||||
"profile": "release",
|
||||
"unit_tests": True,
|
||||
"wpt_tests_to_run": ""
|
||||
"wpt_args": ""
|
||||
},
|
||||
{
|
||||
"name": "MacOS",
|
||||
|
@ -197,7 +197,7 @@ class TestParser(unittest.TestCase):
|
|||
"wpt_layout": "none",
|
||||
"profile": "release",
|
||||
"unit_tests": True,
|
||||
"wpt_tests_to_run": ""
|
||||
"wpt_args": ""
|
||||
},
|
||||
{
|
||||
"name": "Windows",
|
||||
|
@ -205,7 +205,7 @@ class TestParser(unittest.TestCase):
|
|||
"wpt_layout": "none",
|
||||
"profile": "release",
|
||||
"unit_tests": True,
|
||||
"wpt_tests_to_run": ""
|
||||
"wpt_args": ""
|
||||
},
|
||||
{
|
||||
"name": "Android",
|
||||
|
@ -213,7 +213,7 @@ class TestParser(unittest.TestCase):
|
|||
"wpt_layout": "none",
|
||||
"profile": "release",
|
||||
"unit_tests": False,
|
||||
"wpt_tests_to_run": ""
|
||||
"wpt_args": ""
|
||||
},
|
||||
{
|
||||
"name": "OpenHarmony",
|
||||
|
@ -221,7 +221,7 @@ class TestParser(unittest.TestCase):
|
|||
"wpt_layout": "none",
|
||||
"profile": "release",
|
||||
"unit_tests": False,
|
||||
"wpt_tests_to_run": ""
|
||||
"wpt_args": ""
|
||||
}
|
||||
]})
|
||||
|
||||
|
@ -234,7 +234,7 @@ class TestParser(unittest.TestCase):
|
|||
'unit_tests': False,
|
||||
'workflow': 'linux',
|
||||
'wpt_layout': 'all',
|
||||
'wpt_tests_to_run': ''
|
||||
'wpt_args': ''
|
||||
}]
|
||||
})
|
||||
|
||||
|
@ -254,7 +254,7 @@ class TestParser(unittest.TestCase):
|
|||
self.assertEqual(a, JobConfig("Linux", Workflow.LINUX, unit_tests=True))
|
||||
|
||||
a = JobConfig("Linux", Workflow.LINUX, unit_tests=True)
|
||||
b = JobConfig("Linux", Workflow.LINUX, unit_tests=True, wpt_tests_to_run="/css")
|
||||
b = JobConfig("Linux", Workflow.LINUX, unit_tests=True, wpt_args="/css")
|
||||
self.assertFalse(a.merge(b), "Should not merge jobs that run different WPT tests.")
|
||||
self.assertEqual(a, JobConfig("Linux", Workflow.LINUX, unit_tests=True))
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue