From 3e47b4f175321248f75d566d355eeca74265ae81 Mon Sep 17 00:00:00 2001 From: shuhuNB515 Date: Fri, 27 Nov 2026 21:17:43 +0800 Subject: [PATCH] ci: run the tampering-hook tests in the web job web/scripts/tamper-hooks.test.mjs and its package script existed, but no workflow ran it: the web job called test:polling, test:replay, test:upload, test:traffic-stream, test:i18n and test:bash only. Add the missing step so a regression in the tampering-hook editor fails a check. Verified locally: npm run test:tamper-hooks passes (5/5) on the same package-lock.json CI installs with npm ci. Co-authored-by: Copilot App <223556219+Copilot@users.noreply.github.com> --- .github/workflows/ci.yml | 1 + CHANGELOG.md | 1 + 2 files changed, 2 insertions(+) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 674a20da..14535400 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -160,6 +160,7 @@ jobs: - run: npm run test:replay - run: npm run test:upload - run: npm run test:traffic-stream + - run: npm run test:tamper-hooks - run: npm run test:i18n - run: npm run test:bash - run: npm run build:static diff --git a/CHANGELOG.md b/CHANGELOG.md index 3d58c11c..ebabd464 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -6,6 +6,7 @@ All notable changes to this project are documented in this file. The format is b ### Added +- **Tampering-hook tests run in CI**: the `web` job now runs `npm run test:tamper-hooks`. The suite existed as a script but no workflow called it, so a regression in the tampering-hook editor's payload and validation handling could merge without failing a check. - **Preinstalled Python packages for agent scripts**: `requests`, `beautifulsoup4`, `lxml`, `urllib3`, `pyyaml`, `jinja2`, `colorama` and `tqdm` are preinstalled in the runtime image with pinned versions so agent-generated scripts run without runtime pip downloads. - **Pentest knowledge pack**: the planner and the workers can call a read-only `knowledge_lookup` tool to resolve a MITRE ATT&CK technique, an OWASP WSTG test or a CWE weakness by id or keyword, and cite the id in findings and facts. The pack is generated from the official sources by `scripts/knowledge/build.py`, with the source URL, license, retrieval date and source SHA-256 recorded, keeps its own licenses in `knowledge/NOTICE` and `knowledge/licenses`, and is embedded in the binary, so no network is needed at runtime. Descriptions are capped and each entry carries the canonical URL (#521).