- Fixed init_connections() to allow 0 connections for server-only mode - All instances now require [server] section for bind socket - Added test configs demonstrating server-only and client-with-server patterns - Created run_two_instance_test.sh for manual handshake testing
25 lines
483 B
Bash
Executable File
25 lines
483 B
Bash
Executable File
#!/bin/bash
|
|
|
|
# Test script for ETCP connection establishment with real instances
|
|
|
|
DIR=$(cd "$(dirname "$0")" && pwd)
|
|
|
|
echo "=== ETCP Two-Instance Test ==="
|
|
echo
|
|
|
|
# Start server instance in background
|
|
echo "Starting server instance..."
|
|
$DIR/test_server_only &
|
|
SERVER_PID=$!
|
|
sleep 1
|
|
|
|
# Start client instance
|
|
echo "Starting client instance..."
|
|
timeout 10 $DIR/test_server_only 2>&1
|
|
|
|
# Cleanup
|
|
kill $SERVER_PID 2>/dev/null
|
|
wait $SERVER_PID 2>/dev/null
|
|
|
|
echo
|
|
echo "=== Test completed ===" |