openclaw/src/test-utils
scoootscooob 439c21e078
refactor: remove channel shim directories, point all imports to extensions (#45967)
* refactor: remove channel shim directories, point all imports to extensions

Delete the 6 backward-compat shim directories (src/telegram, src/discord,
src/slack, src/signal, src/imessage, src/web) that were re-exporting from
extensions. Update all 112+ source files to import directly from
extensions/{channel}/src/ instead of through the shims.

Also:
- Move src/channels/telegram/ (allow-from, api) to extensions/telegram/src/
- Fix outbound adapters to use resolveOutboundSendDep (fixes 5 pre-existing TS errors)
- Update cross-extension imports (src/web/media.js → extensions/whatsapp/src/media.js)
- Update vitest, tsdown, knip, labeler, and script configs for new paths
- Update guard test allowlists for extension paths

After this, src/ has zero channel-specific implementation code — only the
generic plugin framework remains.

* fix: update raw-fetch guard allowlist line numbers after shim removal

* refactor: document direct extension channel imports

* test: mock transcript module in delivery helpers
2026-03-14 03:43:07 -07:00
..
auth-token-assertions.ts test: dedupe agent tests and session helpers 2026-02-22 17:11:54 +00:00
camera-url-test-helpers.ts refactor(nodes): dedupe camera payload and node resolve helpers 2026-03-02 23:32:41 +00:00
channel-plugin-test-fixtures.ts refactor(test-utils): share direct channel plugin test fixture 2026-03-07 17:58:31 +00:00
channel-plugins.test.ts refactor: eliminate jscpd clones and boost tests 2026-02-19 15:08:54 +00:00
channel-plugins.ts refactor(gateway): hard-break plugin wildcard http handlers 2026-03-02 16:24:06 +00:00
chunk-test-helpers.ts
command-runner.ts test: dedupe and optimize test suites 2026-02-19 15:19:38 +00:00
env.test.ts refactor(agents): dedupe plugin hooks and test helpers 2026-02-22 07:44:57 +00:00
env.ts refactor(agents): dedupe plugin hooks and test helpers 2026-02-22 07:44:57 +00:00
exec-assertions.ts test: fix CI type regressions 2026-03-13 19:53:40 +00:00
fetch-mock.ts
fixture-suite.ts test: dedupe fixtures and test harness setup 2026-02-23 05:45:54 +00:00
frozen-time.ts refactor(test): extract cron issue-regression harness and frozen-time helper 2026-03-03 01:44:21 +00:00
imessage-test-plugin.ts refactor: remove channel shim directories, point all imports to extensions (#45967) 2026-03-14 03:43:07 -07:00
internal-hook-event-payload.ts
mock-http-response.ts diffs plugin 2026-02-28 18:38:00 -05:00
model-auth-mock.ts
model-fallback.mock.ts fix(agents): handle overloaded failover separately (#38301) 2026-03-07 01:42:11 +03:00
npm-spec-install-test-helpers.ts fix(security): stage installs before publish 2026-03-07 19:11:07 +00:00
ports.ts
provider-usage-fetch.ts
repo-scan.ts test: share runtime scan filters and cached test scans 2026-02-22 12:44:44 +01:00
runtime-group-policy-contract.ts test: share runtime group policy fallback cases 2026-03-10 22:20:19 +00:00
runtime-source-guardrail-scan.ts refactor: make OutboundSendDeps dynamic with channel-ID keys (#45517) 2026-03-14 02:42:21 -07:00
secret-file-fixture.ts test: deduplicate cli option collision fixtures 2026-03-10 20:34:54 +00:00
secret-ref-test-vectors.ts Secrets: reject exec SecretRef traversal ids across schema/runtime/gateway (#42370) 2026-03-10 13:45:37 -05:00
send-payload-contract.ts test: extract sendpayload outbound contract suite 2026-03-10 20:35:03 +00:00
symlink-rebind-race.ts fix(security): harden file installs and race-path tests 2026-03-02 19:30:02 +00:00
system-run-prepare-payload.ts refactor(security): simplify system.run approval model 2026-03-11 01:43:06 +00:00
temp-dir.ts test(utils): share temp-dir helper across cli and web tests 2026-02-22 07:44:57 +00:00
temp-home.test.ts fix(ci): normalize path assertions across platforms 2026-02-19 15:28:14 +00:00
temp-home.ts test: share temp home env harness 2026-02-19 15:08:14 +00:00
tracked-temp-dirs.ts perf(test): reduce temp fixture churn in guardrail-heavy suites 2026-03-03 01:09:07 +00:00
typed-cases.ts refactor(test): stabilize case tables and readonly helper inputs 2026-02-22 00:10:07 +01:00
vitest-mock-fn.ts