Skip to content

armgit / ECC

Public Imported from GitHub
0

The agent harness performance optimization system. Skills, instincts, memory, security, and research-first development for Claude Code, Codex, Opencode, Cursor and beyond.

test(opencode): guard plugin.tool existence before shape assertion

van3hardyb2a8091440f8
diff --git a/tests/scripts/build-opencode.test.js b/tests/scripts/build-opencode.test.js
index 4a3aac797..469165883 100644
--- a/tests/scripts/build-opencode.test.js
+++ b/tests/scripts/build-opencode.test.js
@@ -90,6 +90,7 @@ function main() {
for (const hook of expectedHooks) {
assert.strictEqual(typeof plugin[hook], "function", "missing hook: " + hook)
}
+ assert.ok(plugin.tool && typeof plugin.tool === "object", "plugin record must expose a tool object")
assert.deepStrictEqual(
Object.keys(plugin.tool).sort(),
["changed-files", "dependency-analyzer"],