- Removed ImportManager class and exports (use brain.import() instead) - Fixed all documentation: getStatistics() → getStats() - Updated 41 files across codebase for consistency - Removed ImportManager section from API docs - Added v3.30.0 migration guide to CHANGELOG Co-Authored-By: Claude <noreply@anthropic.com>
32 lines
No EOL
1 KiB
JavaScript
32 lines
No EOL
1 KiB
JavaScript
#!/usr/bin/env node
|
|
|
|
/**
|
|
* Quick CLI API Compatibility Test
|
|
*/
|
|
|
|
import { Brainy } from '../../dist/index.js'
|
|
|
|
console.log('🧠 Testing CLI API compatibility...')
|
|
|
|
const brain = new Brainy({ storage: { type: 'memory' }, verbose: false })
|
|
|
|
try {
|
|
console.log('✅ Brainy instantiated')
|
|
|
|
// Test method signatures
|
|
console.log('✅ addNoun method:', typeof brain.addNoun === 'function')
|
|
console.log('✅ addVerb method:', typeof brain.addVerb === 'function')
|
|
console.log('✅ search method:', typeof brain.search === 'function')
|
|
console.log('✅ find method:', typeof brain.find === 'function')
|
|
console.log('✅ updateNoun method:', typeof brain.updateNoun === 'function')
|
|
console.log('✅ deleteNoun method:', typeof brain.deleteNoun === 'function')
|
|
console.log('✅ getStatistics method:', typeof brain.getStats === 'function')
|
|
|
|
console.log('\n🎯 CLI API Compatibility: 100% ✅')
|
|
console.log('All required methods exist with correct names')
|
|
|
|
} catch (error) {
|
|
console.log('❌ API Test Failed:', error.message)
|
|
}
|
|
|
|
process.exit(0) |