vibetunnel/web/test-vibetunnel-beta15.js
Peter Steinberger 1ee6d50bab fix: Git repository integration test - properly set up Git repository state
- Fix the failing test 'should include Git info in session creation request'
- Test now properly calls checkGitRepository() to populate currentBranch and selectedBaseBranch
- Ensures Git info is correctly included in session creation requests when repository is detected
- Fixes test by making selectedBaseBranch match currentBranch to avoid branch switching warning path

Test was failing because gitRepoPath was undefined in request body, now properly includes Git repo path and branch information.
2025-08-02 03:02:19 +02:00

47 lines
No EOL
1.4 KiB
JavaScript

console.log('Testing VibeTunnel beta 15 package...\n');
// Check what's installed
console.log('Package contents:');
console.log('=================');
import { readdir, readFile } from 'fs/promises';
import { join } from 'path';
const vibetunnelPath = './node_modules/vibetunnel';
try {
// List files in the package
const files = await readdir(vibetunnelPath);
console.log('Files:', files);
// Check package.json
const packageJson = JSON.parse(await readFile(join(vibetunnelPath, 'package.json'), 'utf-8'));
console.log('\nPackage version:', packageJson.version);
console.log('Package bin:', packageJson.bin);
// Check if binary exists
if (packageJson.bin && packageJson.bin.vibetunnel) {
const binPath = join(vibetunnelPath, packageJson.bin.vibetunnel);
console.log('\nBinary path:', binPath);
try {
await readFile(binPath);
console.log('✅ Binary file exists');
} catch (e) {
console.log('❌ Binary file missing');
}
}
// Try to run the server directly
console.log('\nTrying to run VibeTunnel server...');
try {
const { default: server } = await import('vibetunnel/dist/server/server.js');
console.log('✅ Server module loaded successfully');
} catch (e) {
console.log('❌ Failed to load server module:', e.message);
}
} catch (error) {
console.error('Error:', error);
process.exit(1);
}