feat(01-03): implement Kimi paths layout and local guard
- Resolve Kimi global skills under the generic agents path - Add empty Kimi layout placeholder and local install no-op guard - Keep selection/path tests aligned without Kimi skill conversion
This commit is contained in:
@@ -48,6 +48,7 @@ const RUNTIME_META = {
|
||||
cursor: { localDir: '.cursor', globalSuffix: '.cursor' },
|
||||
gemini: { localDir: '.gemini', globalSuffix: '.gemini' },
|
||||
hermes: { localDir: '.hermes', globalSuffix: '.hermes' },
|
||||
kimi: { localDir: '.kimi', globalSuffix: path.join('.config', 'agents') },
|
||||
kilo: { localDir: '.kilo', globalSuffix: path.join('.config', 'kilo') },
|
||||
opencode: { localDir: '.opencode', globalSuffix: path.join('.config', 'opencode') },
|
||||
qwen: { localDir: '.qwen', globalSuffix: '.qwen' },
|
||||
|
||||
@@ -649,17 +649,17 @@ describe('Kilo source integration assertions', () => {
|
||||
path.join(__dirname, '..', 'gsd-core', 'bin', 'lib', 'update-context.cjs'), 'utf8');
|
||||
|
||||
test('--kilo flag parsing exists', () => {
|
||||
assert.ok(src.includes("args.includes('--kilo')"));
|
||||
assert.ok(src.includes("runtimeArgs.includes('--kilo')"));
|
||||
});
|
||||
|
||||
test('runtimeMap has Kilo as option 11', () => {
|
||||
assert.strictEqual(runtimeMap['11'], 'kilo');
|
||||
test('runtimeMap has Kilo as option 12 after Kimi', () => {
|
||||
assert.strictEqual(runtimeMap['12'], 'kilo');
|
||||
});
|
||||
|
||||
test('prompt text shows Kilo above OpenCode without marketing copy', () => {
|
||||
const plain = stripAnsi(buildRuntimePromptText());
|
||||
assert.ok(/\b11\)\s*Kilo\b/.test(plain));
|
||||
assert.ok(plain.indexOf('11) Kilo') < plain.indexOf('OpenCode'));
|
||||
assert.ok(/\b12\)\s*Kilo\b/.test(plain));
|
||||
assert.ok(plain.indexOf('12) Kilo') < plain.indexOf('OpenCode'));
|
||||
assert.ok(!plain.includes('the #1 AI coding platform on OpenRouter'));
|
||||
});
|
||||
|
||||
|
||||
@@ -18,6 +18,7 @@ const assert = require('node:assert/strict');
|
||||
const {
|
||||
runtimeMap,
|
||||
allRuntimes,
|
||||
selectRuntimesFromArgs,
|
||||
parseRuntimeInput,
|
||||
buildRuntimePromptText,
|
||||
} = require('../bin/install.js');
|
||||
@@ -48,7 +49,7 @@ describe('multi-runtime selection parsing', () => {
|
||||
|
||||
test('space-separated choices return multiple runtimes', () => {
|
||||
assert.deepStrictEqual(parseRuntimeInput('1 7 9'), ['claude', 'copilot', 'gemini']);
|
||||
assert.deepStrictEqual(parseRuntimeInput('8 11'), ['cursor', 'kilo']);
|
||||
assert.deepStrictEqual(parseRuntimeInput('8 12'), ['cursor', 'kilo']);
|
||||
});
|
||||
|
||||
test('mixed comma and space separators work', () => {
|
||||
@@ -122,7 +123,7 @@ describe('multi-runtime selection parsing', () => {
|
||||
|
||||
test('preserves selection order', () => {
|
||||
assert.deepStrictEqual(parseRuntimeInput('9,1,7'), ['gemini', 'claude', 'copilot']);
|
||||
assert.deepStrictEqual(parseRuntimeInput('11,2,8'), ['kilo', 'antigravity', 'cursor']);
|
||||
assert.deepStrictEqual(parseRuntimeInput('12,2,8'), ['kilo', 'antigravity', 'cursor']);
|
||||
});
|
||||
});
|
||||
|
||||
@@ -169,6 +170,17 @@ describe('install.js exports multi-select runtime metadata', () => {
|
||||
assert.deepStrictEqual(parseRuntimeInput('17'), allRuntimes);
|
||||
});
|
||||
|
||||
test('--kimi flag selects Kimi without interactive prompt', () => {
|
||||
assert.deepStrictEqual(selectRuntimesFromArgs(['--kimi']), ['kimi']);
|
||||
});
|
||||
|
||||
test('--all flag includes Kimi exactly once', () => {
|
||||
const selected = selectRuntimesFromArgs(['--all']);
|
||||
assert.ok(selected.includes('kimi'), '--all includes kimi');
|
||||
assert.strictEqual(selected.filter((runtime) => runtime === 'kimi').length, 1,
|
||||
'--all includes kimi exactly once');
|
||||
});
|
||||
|
||||
test('prompt lists Hermes Agent (10), Kimi (11), Qwen Code (14), Trae (15), and All (17)', () => {
|
||||
const prompt = stripAnsi(buildRuntimePromptText());
|
||||
assert.ok(/\b10\)\s*Hermes Agent\b/.test(prompt),
|
||||
|
||||
Reference in New Issue
Block a user