test(release): derive Codex plugin version from package metadata

Make the Codex marketplace release test follow package.json instead of pinning the previous release version, so scripted release prepares can bump plugin manifests safely.
This commit is contained in:
sickn33
2026-03-27 10:51:25 +01:00
parent 169077e9fb
commit fbbc53843c

View File

@@ -7,10 +7,12 @@ const projectRoot = findProjectRoot(__dirname);
const marketplacePath = path.join(projectRoot, ".agents", "plugins", "marketplace.json");
const editorialBundlesPath = path.join(projectRoot, "data", "editorial-bundles.json");
const compatibilityPath = path.join(projectRoot, "data", "plugin-compatibility.json");
const packageJsonPath = path.join(projectRoot, "package.json");
const marketplace = JSON.parse(fs.readFileSync(marketplacePath, "utf8"));
const editorialBundles = JSON.parse(fs.readFileSync(editorialBundlesPath, "utf8")).bundles || [];
const compatibility = JSON.parse(fs.readFileSync(compatibilityPath, "utf8")).skills || [];
const compatibilityById = new Map(compatibility.map((skill) => [skill.id, skill]));
const packageJson = JSON.parse(fs.readFileSync(packageJsonPath, "utf8"));
assert.strictEqual(
marketplace.name,
@@ -61,7 +63,7 @@ const pluginManifestPath = path.join(pluginRoot, ".codex-plugin", "plugin.json")
const pluginManifest = JSON.parse(fs.readFileSync(pluginManifestPath, "utf8"));
assert.strictEqual(pluginManifest.name, "antigravity-awesome-skills");
assert.strictEqual(pluginManifest.version, "8.10.0");
assert.strictEqual(pluginManifest.version, packageJson.version);
assert.strictEqual(pluginManifest.skills, "./skills/");
const pluginSkillsPath = path.join(pluginRoot, "skills");