Spaces:
Running
Running
File size: 1,174 Bytes
60b6623 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 |
#!/usr/bin/env node
/**
* Integration Test Runner
*
* This script runs all frontend integration tests using Vitest.
* Integration tests verify that different components work together correctly.
*/
import { execSync } from 'child_process';
import { glob } from 'glob';
import path from 'path';
console.log('π§ͺ Frontend Integration Test Runner');
console.log('=====================================\n');
// Find all integration test files
const testFiles = glob.sync('src/test/integration/**/*.test.tsx');
if (testFiles.length === 0) {
console.log('β No integration test files found');
process.exit(1);
}
console.log(`π Found ${testFiles.length} integration test files:`);
testFiles.forEach(file => {
console.log(` - ${file}`);
});
console.log('\nπ Running integration tests...\n');
try {
// Run integration tests with Vitest
const command = `npx vitest run src/test/integration --reporter=verbose`;
execSync(command, { stdio: 'inherit' });
console.log('\nβ
All integration tests completed successfully!');
} catch (error) {
console.error('\nβ Integration tests failed!');
console.error('Error:', error);
process.exit(1);
}
|