Community编程与开发github.com

openclaw-pre-release-plugin-testing

规划和执行 OpenClaw 插件的预发布验证,涵盖捆绑插件、包工件、生命周期命令、doctor/fix、配置往返、网关启动、SDK 兼容性、Docker E2E、包验收和 Testbox 验证。

openclaw-pre-release-plugin-testing 是什么?

此技能旨在为 OpenClaw 插件系统进行全面的预发布测试,确保插件作为一个产品表面层,而不仅仅是源代码测试。它覆盖了插件的完整生命周期(安装、查看、启用、禁用、卸载)、包工件的行为验证、doctor/fix 配置验证和幂等性、配置发现与往返测试、状态/日志可见性、网关启动与插件元数据快照、公共 SDK 的兼容性测试(针对真实外部插件),以及在安全凭证存在时进行轻量化的实时提供者/通道探测。技能文档详细列出了多种测试运行器(如 GitHub Package Acceptance、Blacksmith Testbox、本地命令)的选择优先级、现有基线测试命令、用于签收的置信矩阵、新的 Testbox 测试计划(包括插件安装/卸载、doctor/fix、网关启动和配置往返的详细步骤),以及外部 SDK 烟雾测试和报告模板。该技能特别适用于发布前的最终验证,帮助开发者识别和填补测试空白,确保插件系统的稳定性和可靠性。

兼容平台✓Claude Code✓Codex CLI~Cursor
npx skills add https://github.com/clawdbot/clawdbot/tree/main/.agents/skills/openclaw-pre-release-plugin-testing

Installed? Explore more 编程与开发 skills: steipete/bluebubbles, steipete/eightctl, steipete/blucli · View all 6 →

在你喜欢的 AI 中提问

打开一个已预加载此 Agent Skill 的新对话。

文档

OpenClaw 预发布插件测试

当用户要求进行插件发布信心评估、插件生命周期扫描、包工件插件验证或“发布前我们还应测试什么?”时使用此技能。此技能与 openclaw-testing 相辅相成;在选择最便宜的安全运行器或调试失败的测试用例时,也应同时使用该技能。

目标

证明插件系统作为产品表面层的完整性,而不仅仅是源代码测试:

  • 捆绑插件生命周期:安装、查看、启用、禁用、卸载
  • 在干净的 HOME 下验证包工件行为
  • doctor/fix/配置验证及其幂等性
  • 配置发现和配置往返测试
  • 状态/日志可见性和诊断信息
  • 网关启动/引导,包含插件元数据快照
  • 针对真实外部插件的公共 SDK 兼容性测试
  • 仅在安全凭证存在时进行轻量化的实时提供者/通道探测

初始检查

在 OpenClaw 仓库根目录下执行:

pnpm docs:list
git status --short --branch
readlink node_modules
pnpm changed:lanes --json

在 .codex/worktrees 下的 Codex 工作树中,node_modules 必须是主 OpenClaw 检出目录的符号链接。请勿在此处运行 pnpm install。对于广泛的或依赖包的验证,请使用 Blacksmith Testbox 或 GitHub Actions。

运行器选择

优先按以下顺序选择:

  1. GitHub Package Acceptance 用于可安装包的制品验证。
  2. ci-build-artifacts-testbox.yml Testbox 当 Docker/包测试需要预先填充的 dist、dist-runtime 和包缓存时。
  3. ci-check-testbox.yml Testbox 用于源代码检查、有针对性的 Vitest、包边界检查或集中的 Docker 测试。
  4. 仅限本地有针对性的命令 用于小范围的格式/静态/单元测试。

避免在陈旧的稀疏工作树上运行耗时的包 Docker 测试。如果 Testbox 同步报告大量文件变更或开始删除包输入,请停止并从当前 main 分支启动一个新的环境,或切换到 Package Acceptance。

现有基线测试

在创建新的测试覆盖之前,请运行或验证以下测试:

OPENCLAW_TESTBOX=1 pnpm check:changed
pnpm run test:extensions:package-boundary:canary
pnpm run test:extensions:package-boundary:compile
pnpm test:docker:plugins
OPENCLAW_PLUGINS_E2E_CLAWHUB=0 pnpm test:docker:plugins
pnpm test:docker:plugin-update
pnpm test:docker:bundled-channel-deps:fast

对于完整的捆绑安装/卸载验证,请分片运行打包扫描:

OPENCLAW_BUNDLED_PLUGIN_SWEEP_TOTAL=8 \
OPENCLAW_BUNDLED_PLUGIN_SWEEP_INDEX=<0-7> \
pnpm test:docker:bundled-plugin-install-uninstall

当前预期的打包范围:分片 0-7 中包含 116 个公共捆绑插件。私有 QA 插件仅在源代码模式下可用,除非包明确包含它们。

置信矩阵

使用以下矩阵进行预发布签收。记录通过/失败状态、运行 URL/Testbox ID、包 SHA/版本以及跳过实时测试的原因。

测试面验证方法首选运行器
包工件Package Acceptance suite_profile=package 或自定义测试GitHub Actions
捆绑生命周期8 分片 test:docker:bundled-plugin-install-uninstallTestbox 或发布 Docker
外部插件test:docker:plugins 和 plugins-offlineTestbox/包验收
更新无操作test:docker:plugin-updateTestbox/包验收
通道运行时依赖test:docker:bundled-channel-deps:fast 加关键通道Testbox/包验收
Doctor/fix注入异常配置 + doctor --fix --non-interactive新的 Docker/Testbox 测试框架
配置往返config set/get、查看、doctor、重载、哈希比较新的 Docker/Testbox 测试框架
网关启动干净的 HOME、启用/禁用插件组、状态 JSON新的 Docker/Testbox 测试框架
SDK 兼容性使用 SDK 子路径的目录、tgz 和 file: 外部插件test:docker:plugins 加新的集成测试
轻量化实时测试仅为存在的环境变量进行脱敏的提供者/通道探测Testbox 实时测试

Package Acceptance 计划

在验证发布分支、测试版或候选包时使用:

gh workflow run package-acceptance.yml \
  --repo openclaw/openclaw \
  --ref main \
  -f workflow_ref=main \
  -f source=ref \
  -f package_ref=<branch-or-sha> \
  -f suite_profile=custom \
  -f docker_lanes='plugins-offline plugin-update bundled-channel-deps-compat doctor-switch update-channel-switch config-reload mcp-channels npm-onboard-channel-agent' \
  -f telegram_mode=mock-openai

对于已发布的测试版验证,使用 source=npm -f package_spec=openclaw@beta。除非发布流程另有说明,否则保持 workflow_ref 为当前可信的框架代码。

新 Testbox 测试框架计划

如果需要更高的确定性,请添加或运行一个 plugin-lifecycle-matrix Docker 测试,该测试使用一个包 tarball 和分片的插件列表。每个插件执行:

  1. 从干净的 HOME 开始。
  2. 获取 plugins list --json。
  3. plugins install <id>。
  4. plugins inspect <id> --json。
  5. plugins disable <id>,然后断言禁用状态的可见性。
  6. plugins enable <id>,但配置要求的插件在没有配置时除外。
  7. plugins registry --refresh。
  8. doctor --non-interactive。
  9. plugins uninstall <id> --force。
  10. 断言没有残留的配置条目、允许/拒绝记录、安装记录、管理目录或捆绑的 dist/extensions/... 加载路径。
  11. 断言诊断信息中不包含 level: "error",并且输出已脱敏可能包含秘密的值。

特别注意 memory-lancedb:它是配置要求的。首先断言安装时未提供嵌入配置不会启用它,然后运行第二个配置后的案例。

Doctor/Fix 矩阵

注入错误状态并要求 doctor --fix --non-interactive 修复它们,然后再次运行 doctor 并验证幂等性:

  • 过时的 plugins.allow
  • 过时的 plugins.entries
  • 针对缺失通道插件的过时通道配置
  • 无效的 plugins.entries.<id>.config
  • plugins.load.paths 中的打包捆绑路径
  • 遗留的 plugins.installs
  • 被禁用但配置要求禁止暂存运行时依赖的通道/插件配置
  • 必须保持未修改的、由 root 拥有的全局包目录

网关启动矩阵

在 Docker 中以干净状态启动打包的 OpenClaw:

  • 启用了提供者插件但无凭据:就绪并显示警告,无崩溃
  • 配置了禁用的通道插件:不暂存运行时依赖
  • 启用了启动激活插件:就绪并在状态中反映
  • 单个插件配置无效:该插件被跳过/隔离,其余插件保持正常

断言:

  • 网关达到就绪状态
  • openclaw status --json 包含插件诊断信息
  • openclaw plugins inspect --all --json 可解析
  • 包目录未被修改
  • 日志中不包含原始令牌

配置往返代表

使用有代表性的插件族进行深度配置往返测试,而非每个插件:

  • 提供者:openai、anthropic、mistral、openrouter
  • 通道:telegram、discord、slack、whatsapp
  • 内存:memory-lancedb
  • 特性/运行时:browser、acpx、tokenjuice

对于每个代表:

  1. 尽可能通过 CLI 写入配置。
  2. 通过 config get 或 JSON 读回配置。
  3. 运行 plugins inspect。
  4. 运行 doctor --non-interactive。
  5. 如果适用,触发网关配置重载。
  6. 在无操作命令前后比较配置哈希值。

外部 SDK 烟雾测试

在包 Docker 测试中,创建小型外部插件并从以下位置安装:

  • 本地目录
  • .tgz 文件
  • file: npm 规范

覆盖 CJS 和 ESM 两种形态,并至少包含一个导入 openclaw/plugin-sdk/* 子路径的插件。断言 plugins inspect 能识别出其工具、网关方法、CLI 命令或服务。

轻量化实时探测规则

在进行轻量化实时工作之前,在 Testbox 中获取允许的环境变量并生成脱敏的可用性矩阵:仅显示存在/缺失状态,绝不显示具体值。

仅对存在的凭证运行探测。优先使用认证/目录/状态探测,避免发送用户可见的消息。如果探测可能联系到外部用户、通道或工作空间,请停止并询问用户。

报告

按以下格式报告:

package/ref:
tbx ids / run urls:
matrix:
  bundled lifecycle:
  package acceptance:
  doctor/fix:
  gateway bootstrap:
  config round-trip:
  sdk external:
  live-ish:
failures:
skips:
next highest-value gap:

明确指出失败是由 Testbox 同步/环境损坏还是产品行为引起的,并通过干净的重新运行或与当前 main 分支的比较来证明。

Individual skills in this repo

This repo contains 20 individual skills — each has its own dedicated page.

1password

Set up and use 1Password CLI for sign-in, desktop integration, and reading or injecting secrets.

acp-router

Route plain-language requests for Claude Code, Cursor, Copilot, OpenClaw ACP, OpenCode, Gemini CLI, Grok Build, Qwen, Kiro, Kimi, iFlow, Factory Droid, Kilocode, or explicit ACP harness work into either OpenClaw ACP runtime sessions or direct acpx-driven sessions ("telephone game" flow). For coding-agent thread requests, read this skill first, then use only `sessions_spawn` for thread creation. Codex chat binding defaults to the native Codex app-server plugin unless ACP is explicit or background spawn needs ACP.

add-model-provider

Add and live-prove a model provider with non-interactive config one-liners, without exposing credentials.

agent-transcript

Requested GitHub PR/issue agent transcripts: redact, trim, preview, and insert safely.

apple-notes

Create, view, edit, delete, search, move, or export Apple Notes via the memo CLI on macOS.

apple-reminders

List, add, edit, complete, or delete Apple Reminders and reminder lists via remindctl.

auto-qa

Run OpenClaw-wide autonomous QA and live/stress campaigns across independent subsystem lanes, with verified fixes and a resumable evidence report.

autoreview

Structured code review through the shared OpenClaw agent-skills installation.

bear-notes

Create, search, and manage Bear notes via grizzly CLI.

blacksmith-testbox

Run Blacksmith Testbox for CI-parity checks, secrets, hosted services, migrations, or builds local cannot reproduce.

block-kit

Use proactively for structured or interactive Slack replies, and when asked to author or validate native Slack Block Kit JSON.

blogwatcher

Monitor blogs and RSS/Atom feeds for updates using the blogwatcher CLI.

blucli

BluOS CLI (blu) for discovery, playback, grouping, and volume.

bluebubbles

Send and manage iMessages via BlueBubbles, including attachments, tapbacks, edits, replies, and groups.

browser-automation

Use when controlling web pages with the OpenClaw browser tool, especially multi-step flows, login checks, tab management, or recovery from stale refs/timeouts.

camsnap

Capture frames or clips from RTSP/ONVIF cameras and local webcams, including USB pan/tilt/zoom control.

canvas

Present HTML on connected OpenClaw node canvases, navigate/eval/snapshot, and debug canvas host URLs.

channel-message-flows

Use when running QA Lab channel message flow evidence.

clawdtributor

Clawtributor PRs here, last week or another window: discover conversation refs, recheck GitHub, rank by impact.

clawhub

Search ClawHub for plugins by default, or skills and agent Templates when requested; add Templates; install, verify, update, uninstall, publish, or sync skills.

相关技能