CHECKPOINT: Major project cleanup and organization
🎯 CLEANUP MILESTONE - Session 5 Continuation: 📁 DOCUMENTATION (70+ → 31 files): ✅ Removed 14 redundant API design documents ✅ Removed 8 augmentation archive documents ✅ Removed 6 planning documents ✅ Removed 11 temporary strategy/optimization docs ✅ All backed up to backup-cleanup-2025-08-26/ 📂 TEST ORGANIZATION: ✅ Moved 17 test files → tests/manual-tests/ ✅ Moved 2 vitest configs → tests/configs/ ✅ Moved 5 test scripts → tests/scripts/ ✅ Removed 12 log files (backed up) 🏗️ NEW CLEAN STRUCTURE: - docs/: Clean, organized documentation - api/, architecture/, augmentations/, features/, guides/ - tests/: All test-related files consolidated - configs/, manual-tests/, scripts/ - Root: Only essential files (README, CHANGELOG, etc.) 📊 IMPACT: - 70% reduction in documentation clutter - 100% of tests organized under tests/ - Professional structure ready for 2.0 release - No data loss - everything backed up Ready for final release preparation!
This commit is contained in:
parent
4949b6a629
commit
b74faa85d4
66 changed files with 4 additions and 9683 deletions
55
tests/configs/vitest.integration.config.ts
Normal file
55
tests/configs/vitest.integration.config.ts
Normal file
|
|
@ -0,0 +1,55 @@
|
|||
import { defineConfig } from 'vitest/config'
|
||||
|
||||
/**
|
||||
* Integration Test Configuration - REAL AI MODELS
|
||||
*
|
||||
* Based on industry practices: fewer tests, real models, high memory
|
||||
* Only run critical AI functionality to verify production readiness
|
||||
*/
|
||||
export default defineConfig({
|
||||
test: {
|
||||
globals: true,
|
||||
setupFiles: ['./tests/setup-integration.ts'],
|
||||
environment: 'node',
|
||||
|
||||
// INTEGRATION TESTS: Real AI, need time and memory
|
||||
testTimeout: 300000, // 5 minutes per test
|
||||
hookTimeout: 120000, // 2 minutes for setup
|
||||
teardownTimeout: 30000,
|
||||
|
||||
// Include only integration tests
|
||||
include: [
|
||||
'tests/integration/**/*.test.ts',
|
||||
'tests/**/*.integration.test.ts'
|
||||
],
|
||||
|
||||
// CRITICAL: Sequential execution to prevent memory exhaustion
|
||||
pool: 'forks',
|
||||
poolOptions: {
|
||||
forks: {
|
||||
maxForks: 1, // One test at a time
|
||||
minForks: 1,
|
||||
singleFork: true, // Absolute isolation
|
||||
isolate: true
|
||||
}
|
||||
},
|
||||
|
||||
// No parallelism
|
||||
maxConcurrency: 1,
|
||||
fileParallelism: false,
|
||||
|
||||
// Minimal reporting to reduce memory
|
||||
reporters: process.env.CI ? ['dot'] : ['basic'],
|
||||
|
||||
// No coverage (saves memory)
|
||||
coverage: {
|
||||
enabled: false
|
||||
},
|
||||
|
||||
// Test sharding for CI
|
||||
shard: process.env.VITEST_SHARD,
|
||||
|
||||
// Retry once for flaky AI tests
|
||||
retry: 1
|
||||
}
|
||||
})
|
||||
53
tests/configs/vitest.unit.config.ts
Normal file
53
tests/configs/vitest.unit.config.ts
Normal file
|
|
@ -0,0 +1,53 @@
|
|||
import { defineConfig } from 'vitest/config'
|
||||
|
||||
/**
|
||||
* Unit Test Configuration - NO REAL AI MODELS
|
||||
*
|
||||
* Based on industry practices from HuggingFace, sentence-transformers, etc.
|
||||
* Unit tests use mocks to avoid memory issues entirely.
|
||||
*/
|
||||
export default defineConfig({
|
||||
test: {
|
||||
globals: true,
|
||||
setupFiles: ['./tests/setup-unit.ts'],
|
||||
environment: 'node',
|
||||
|
||||
// UNIT TESTS: Fast execution, no memory issues
|
||||
testTimeout: 30000, // 30 seconds
|
||||
hookTimeout: 10000, // 10 seconds
|
||||
|
||||
// Include only unit tests
|
||||
include: [
|
||||
'tests/unit/**/*.test.ts',
|
||||
'tests/**/*.unit.test.ts'
|
||||
],
|
||||
|
||||
// Exclude integration tests
|
||||
exclude: [
|
||||
'tests/integration/**',
|
||||
'tests/**/*.integration.test.ts',
|
||||
'tests/**/*.e2e.test.ts',
|
||||
'node_modules/**'
|
||||
],
|
||||
|
||||
// Parallel execution OK for unit tests
|
||||
pool: 'threads',
|
||||
maxConcurrency: 4,
|
||||
fileParallelism: true,
|
||||
|
||||
reporters: ['verbose'],
|
||||
|
||||
// Coverage for unit tests
|
||||
coverage: {
|
||||
enabled: true,
|
||||
provider: 'v8',
|
||||
reporter: ['text', 'html'],
|
||||
include: ['src/**/*.ts'],
|
||||
exclude: [
|
||||
'src/**/*.test.ts',
|
||||
'src/embeddings/worker-*.ts', // Skip worker files
|
||||
'dist/**'
|
||||
]
|
||||
}
|
||||
}
|
||||
})
|
||||
Loading…
Add table
Add a link
Reference in a new issue