Files
opencode-power-pack/tests/pi-package.test.mjs
T
Wayner Barrios 66eac6e8db feat: add Claude Code packaging and skill quality gates (#26)
- add native Claude Code plugin and marketplace manifests
- document Claude Code installation, invocation, updates, and removal
- reduce routing metadata and enforce a catalog budget
- validate Agent Skills and Claude manifests in CI
- remove wooyun-legacy from the package and provenance
- update package metadata and tests for the 54-skill catalog
2026-08-13 17:06:24 -04:00

23 lines
883 B
JavaScript

import { test } from "node:test";
import assert from "node:assert/strict";
import { existsSync, readFileSync, readdirSync } from "node:fs";
import { join } from "node:path";
const REPO = process.env.REPO || process.cwd();
const packageJson = JSON.parse(readFileSync(join(REPO, "package.json"), "utf8"));
test("Pi package declares the bundled skills directory", () => {
assert.deepEqual(packageJson.pi, { skills: ["./skills"] });
assert.ok(packageJson.keywords.includes("pi-package"));
assert.ok(packageJson.keywords.includes("pi-coding-agent"));
assert.match(packageJson.description, /Pi/);
});
test("Pi package exposes all fifty-four SKILL.md workflows", () => {
const skillRoot = join(REPO, packageJson.pi.skills[0]);
const skills = readdirSync(skillRoot)
.filter((name) => existsSync(join(skillRoot, name, "SKILL.md")));
assert.equal(skills.length, 54);
});