fix: let the export step fail as CI does

validate.yml runs export_native with continue-on-error, and pr_checks
failed the whole run on it. The step is now shown and does not fail
the run, and a test keeps that list equal to the workflow's.
This commit is contained in:
Abdessamad Derraz committed 2026-11-06 18:43:05 +01:00
1 parent 3e25870259
commit 7db9fe14e1
2 files changed
+19 -3

No files matched your search

+10
View File
@@ -235,6 +235,16 @@ class OneCommandRunsTheChecks(unittest.TestCase):
with self.subTest(check=check):
self.assertTrue(any(command.startswith(check) for command in steps))
def test_a_step_ci_lets_fail_does_not_fail_the_run(self):
import pr_checks
workflow = (REPO_ROOT / ".github" / "workflows" / "validate.yml").read_text(encoding="utf-8")
tolerated = set(re.findall(r"continue-on-error: true\n\s*run: (\S+ \S+)", workflow))
self.assertTrue(tolerated)
for step in pr_checks.STEPS:
with self.subTest(step=step.command):
self.assertEqual(step.may_fail, " ".join(step.command.split()[:2]) in tolerated)
def test_steps_keep_ci_order(self):
import pr_checks