v31.1-roots.1 · Commit 11: [PATCH 11/17] fix(test): bound policy oracles and retain CI diagnostics
ci/test/test_fuzz_workflows.py
Before: ci/test/test_fuzz_workflows.py · After: ci/test/test_fuzz_workflows.py
File metadata
index e0958bebb713c945e684a6e76f39eb4ce895f6bf..b860c1950b9d5c93bb697813b8be5072bd114911 100755
Download original patch · Release notes
Diff rows 1–17 of 17. Line numbers refer to the original before/after files.
+ Added− RemovedUnmarked lines are context.
Scroll the code area horizontally to read long lines. Before is on the left; after is on the right. Unified view fits narrow screens more easily.
ci/test/test_fuzz_workflows.py
CHANGED
|
@@ -22,6 +22,17 @@ def job(workflow, name):
|
|
| 22 |
|
| 23 |
|
| 24 |
class FuzzWorkflowTest(unittest.TestCase):
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 25 |
def test_full_linux_corpus_is_not_an_ordinary_pr_job(self):
|
| 26 |
workflow = CI_WORKFLOW.read_text(encoding="utf-8")
|
| 27 |
self.assertNotRegex(workflow, r"(?m)^ fuzz:$")
|
|
|
|
| 22 |
|
| 23 |
|
| 24 |
class FuzzWorkflowTest(unittest.TestCase):
|
| 25 |
+
def test_failure_upload_uses_the_explicit_container_artifact_path(self):
|
| 26 |
+
configure = (ROOT / '.github/actions/configure-environment/action.yml').read_text()
|
| 27 |
+
self.assertIn('ROOTS_ARTIFACTS_DIR=${{ runner.temp }}/roots-failures', configure)
|
| 28 |
+
self.assertIn('export ROOTS_ARTIFACTS_DIR=', (ROOT / 'ci/test/00_setup_env.sh').read_text())
|
| 29 |
+
runner = (ROOT / 'ci/test/03_test_script.sh').read_text()
|
| 30 |
+
self.assertEqual(runner.count('--artifacts "${ROOTS_ARTIFACTS_DIR:-${BASE_SCRATCH_DIR}/roots-failures}"'), 2)
|
| 31 |
+
for workflow in (CI_WORKFLOW, NIGHTLY_WORKFLOW, ROOT / '.github/workflows/reusable-sanitizer.yml'):
|
| 32 |
+
text = workflow.read_text()
|
| 33 |
+
self.assertIn('${{ env.ROOTS_ARTIFACTS_DIR }}/', text)
|
| 34 |
+
self.assertNotIn('${{ runner.temp }}/ci/scratch/roots-failures/', text)
|
| 35 |
+
|
| 36 |
def test_full_linux_corpus_is_not_an_ordinary_pr_job(self):
|
| 37 |
workflow = CI_WORKFLOW.read_text(encoding="utf-8")
|
| 38 |
self.assertNotRegex(workflow, r"(?m)^ fuzz:$")
|