mirror of
https://github.com/Manavarya09/design-extract.git
synced 2026-09-19 02:41:14 +08:00
ee68490eb7
README quick-start, a dedicated 'Measured clone fidelity' section, the plugin command table, and the full CLI reference now cover /fidelity and /gallery. CHANGELOG 12.24.0 entry. Version bumped in lockstep across package.json, plugin.json, marketplace.json (manifests describe the two new commands); the version-sync test now guards fidelity + gallery too.
34 lines
1.4 KiB
JavaScript
34 lines
1.4 KiB
JavaScript
// Plugin-manifest health: versions stay in lockstep with package.json, and
|
|
// every command the manifest advertises has a backing file.
|
|
|
|
import { describe, it } from 'node:test';
|
|
import assert from 'node:assert/strict';
|
|
import { readFileSync, existsSync } from 'node:fs';
|
|
import { dirname, resolve, join } from 'node:path';
|
|
import { fileURLToPath } from 'node:url';
|
|
|
|
import { checkPluginVersions } from '../scripts/check-plugin-version.mjs';
|
|
|
|
const root = resolve(dirname(fileURLToPath(import.meta.url)), '..');
|
|
const read = (p) => JSON.parse(readFileSync(resolve(root, p), 'utf-8'));
|
|
|
|
describe('plugin manifest', () => {
|
|
it('keeps plugin.json and marketplace.json in sync with package.json', () => {
|
|
const { ok, problems } = checkPluginVersions();
|
|
assert.equal(ok, true, problems.join('; '));
|
|
});
|
|
|
|
it('ships a command file for every new command added in this release', () => {
|
|
for (const cmd of ['site', 'studio', 'verify', 'fidelity', 'gallery']) {
|
|
assert.ok(existsSync(join(root, 'commands', `${cmd}.md`)), `commands/${cmd}.md missing`);
|
|
}
|
|
});
|
|
|
|
it('describes the new commands in the plugin description', () => {
|
|
const plugin = read('.claude-plugin/plugin.json');
|
|
for (const cmd of ['/site', '/studio', '/verify', '/fidelity', '/gallery']) {
|
|
assert.ok(plugin.description.includes(cmd), `plugin.json description missing ${cmd}`);
|
|
}
|
|
});
|
|
});
|