From ebdae6094ecc105be10fb2e59b13cf63773a4c10 Mon Sep 17 00:00:00 2001 From: Samson <16504129+sagudev@users.noreply.github.com> Date: Fri, 23 Aug 2024 10:58:12 +0200 Subject: CI: Add separate Lint&Tidy check and remove test-tidy from linux (#33150) * Create separate Lint&Tidy check Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com> * Remove quick-check as it's not longer relevant Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com> * Add clippy to rust-toolchain Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com> * fix try parser test expectations Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com> * use lint in result Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com> * Lint & Tidy -> Lint Co-authored-by: Martin Robinson Signed-off-by: Samson <16504129+sagudev@users.noreply.github.com> --------- Signed-off-by: sagudev <16504129+sagudev@users.noreply.github.com> Signed-off-by: Samson <16504129+sagudev@users.noreply.github.com> Co-authored-by: Martin Robinson --- python/servo/try_parser.py | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) (limited to 'python/servo/try_parser.py') diff --git a/python/servo/try_parser.py b/python/servo/try_parser.py index cd19da48d3a..750e0c74424 100644 --- a/python/servo/try_parser.py +++ b/python/servo/try_parser.py @@ -47,6 +47,7 @@ class Workflow(str, Enum): WINDOWS = "windows" ANDROID = "android" OHOS = "ohos" + LINT = "lint" @dataclass @@ -104,6 +105,8 @@ def handle_preset(s: str) -> Optional[JobConfig]: wpt_args="--processes 1 _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 + elif s in ["lint", "tidy"]: + return JobConfig("Lint", Workflow.LINT) else: return None @@ -138,7 +141,7 @@ class Config(object): self.fail_fast = True continue # skip over keyword if word == "full": - words.extend(["linux-wpt", "macos", "windows", "android", "ohos"]) + words.extend(["linux-wpt", "macos", "windows", "android", "ohos", "lint"]) continue # skip over keyword job = handle_preset(word) @@ -222,7 +225,14 @@ class TestParser(unittest.TestCase): "profile": "release", "unit_tests": False, "wpt_args": "" - } + }, + { + "name": "Lint", + "workflow": "lint", + "wpt_layout": "none", + "profile": "release", + "unit_tests": False, + "wpt_args": ""} ]}) def test_job_merging(self): @@ -259,7 +269,7 @@ class TestParser(unittest.TestCase): self.assertEqual(a, JobConfig("Linux", Workflow.LINUX, unit_tests=True)) def test_full(self): - self.assertDictEqual(json.loads(Config("linux-wpt macos windows android ohos").to_json()), + self.assertDictEqual(json.loads(Config("linux-wpt macos windows android ohos lint").to_json()), json.loads(Config("").to_json())) -- cgit v1.2.3