fix(release): make ECC 2.2 ready to publish

This commit is contained in:
haelyra
2026-08-24 20:15:12 -04:00
parent 528dbea019
commit 2c5a91a1d6
15 changed files with 259 additions and 93 deletions
+50
View File
@@ -252,6 +252,38 @@ function findDriftCandidate(state, cursorRoot) {
return resolveManagedExistingPath(operation.destinationPath, cursorRoot).path;
}
function runTargetSmoke(options) {
const install = parseJsonOutput(
options.runCli([
'install',
'--modules', 'workflow-quality',
'--target', options.target,
'--json',
]),
`${options.target} packed install`
);
assert.strictEqual(install.summary.errorCount, 0);
const statePath = path.join(options.targetRoot, 'ecc-install-state.json');
assert.ok(fs.existsSync(statePath), `${options.target} install-state must exist`);
assert.ok(
fs.existsSync(path.join(options.targetRoot, 'skills', 'skill-comply', 'SKILL.md')),
`${options.target} must install skill-comply from the packed archive`
);
const doctor = parseJsonOutput(
options.runCli(['doctor', '--target', options.target, '--json']),
`${options.target} packed doctor`
);
assert.strictEqual(doctor.summary.errorCount, 0);
const uninstall = parseJsonOutput(
options.runCli(['uninstall', '--target', options.target, '--json']),
`${options.target} packed uninstall`
);
assert.strictEqual(uninstall.summary.errorCount, 0);
assert.ok(!fs.existsSync(statePath), `${options.target} uninstall must remove install-state`);
}
function runLifecycle(options) {
assert.ok(fs.existsSync(options.packagePath), `release package does not exist: ${options.packagePath}`);
assertDownloadedArtifact(options.packagePath, process.cwd());
@@ -450,6 +482,22 @@ function runLifecycle(options) {
assert.strictEqual(statusAfterUninstall.installStateProjection.warningCount, 0);
assert.strictEqual(statusAfterUninstall.readiness.status, 'ok');
const antigravityRoot = path.join(projectDir, '.agents');
runTargetSmoke({
runCli,
target: 'antigravity',
targetRoot: antigravityRoot,
});
assert.ok(!fs.existsSync(path.join(projectDir, '.agent')));
const opencodeRoot = path.join(homeDir, '.config', 'opencode');
runTargetSmoke({
runCli,
target: 'opencode',
targetRoot: opencodeRoot,
});
assert.ok(!fs.existsSync(path.join(homeDir, '.opencode')));
return {
packageSha256: options.expectedSha256,
platform: process.platform,
@@ -469,6 +517,8 @@ function runLifecycle(options) {
'uninstall',
'status-uninstalled',
'sentinel-preserved',
'antigravity-install-doctor-uninstall',
'opencode-install-doctor-uninstall',
],
};
} finally {
@@ -162,12 +162,12 @@ test('packed lifecycle invokes installed public bins, including setup help', ()
});
test('packed lifecycle validates canonical Antigravity and OpenCode installs', () => {
assert.match(lifecycleRunnerSource, /'--target', 'antigravity'/);
assert.match(lifecycleRunnerSource, /target:\s*'antigravity'/);
assert.match(lifecycleRunnerSource, /path\.join\(projectDir, '\.agents'\)/);
assert.match(lifecycleRunnerSource, /'--target', 'opencode'/);
assert.match(lifecycleRunnerSource, /target:\s*'opencode'/);
assert.match(lifecycleRunnerSource, /path\.join\(homeDir, '\.config', 'opencode'\)/);
assert.match(lifecycleRunnerSource, /doctor.*antigravity/s);
assert.match(lifecycleRunnerSource, /doctor.*opencode/s);
assert.match(lifecycleRunnerSource, /\['doctor', '--target', options\.target, '--json'\]/);
assert.match(lifecycleRunnerSource, /skill-comply.*SKILL\.md/);
});
test('packed lifecycle installs and verifies the opt-in Ito distribution surface', () => {