mirror of
https://github.com/affaan-m/everything-claude-code.git
synced 2026-07-02 04:51:26 +08:00
fix: resolve issue cluster (#2295,#2298,#2303,#2304,#2305,#2306,#2340) + createdTime fallback bug
- session-manager: fix createdTime birthtime||ctime fallback that never fired (a Date is always truthy); use birthtimeMs>0 check via resolveCreatedTime() - installer: rewrite source-relative rules/skills links for the injected ecc/ namespace so installed skills resolve correctly (#2340) - continuous-learning-v2: drop unused mock import (#2305); standardize bash shebangs (#2303); poll for PID file instead of fixed sleep (#2295); rename _ecc_* -> _clv2_* (#2304); align promotion confidence docs (#2298); de-brittle Scope Decision Guide cross-reference (#2306) Co-Authored-By: Devin AI <158243242+devin-ai-integration[bot]@users.noreply.github.com>
This commit is contained in:
@@ -123,6 +123,40 @@ function runTests() {
|
||||
}
|
||||
})) passed++; else failed++;
|
||||
|
||||
if (test('rewrites namespaced skill links to the ecc/ rules path (#2340)', () => {
|
||||
const homeDir = createTempDir('install-apply-home-');
|
||||
const projectDir = createTempDir('install-apply-project-');
|
||||
|
||||
try {
|
||||
const result = run(['typescript'], { cwd: projectDir, homeDir });
|
||||
assert.strictEqual(result.code, 0, result.stderr);
|
||||
|
||||
const claudeRoot = path.join(homeDir, '.claude');
|
||||
const skillPath = path.join(claudeRoot, 'skills', 'ecc', 'react-patterns', 'SKILL.md');
|
||||
assert.ok(fs.existsSync(skillPath), 'react-patterns SKILL.md should be installed');
|
||||
|
||||
const content = fs.readFileSync(skillPath, 'utf8');
|
||||
assert.ok(
|
||||
content.includes('../../../rules/ecc/react/'),
|
||||
'source-relative rules link should be rewritten for the ecc/ namespace'
|
||||
);
|
||||
assert.ok(
|
||||
!content.includes('](../../rules/'),
|
||||
'no un-namespaced ](../../rules/ links should remain'
|
||||
);
|
||||
|
||||
// The rewritten link must resolve to a file that actually exists on disk.
|
||||
const linkTarget = path.join(
|
||||
path.dirname(skillPath),
|
||||
'../../../rules/ecc/react/hooks.md'
|
||||
);
|
||||
assert.ok(fs.existsSync(linkTarget), 'rewritten link target should exist');
|
||||
} finally {
|
||||
cleanup(homeDir);
|
||||
cleanup(projectDir);
|
||||
}
|
||||
})) passed++; else failed++;
|
||||
|
||||
if (test('installs Cursor configs and writes install-state', () => {
|
||||
const homeDir = createTempDir('install-apply-home-');
|
||||
const projectDir = createTempDir('install-apply-project-');
|
||||
|
||||
Reference in New Issue
Block a user