- Add worker storage layer with PostgreSQL/sqlc setup - Add migration files for worker backbone schema - Add job runner and built-in jobs implementation - Add Redis key definitions for worker state management - Archive socket-session-loop milestone (completed/renamed) - Update roadmap current.md and foundation-alignment phase - Add socket endpoint integration and runtime smoke tests - Add infra-check, worker-storage-check, worker-storage-gen CLI tools - Update API socket server and config - Add pubspec dependencies and client socket endpoint changes - Add config tests for API and worker services
26 lines
940 B
Dart
26 lines
940 B
Dart
import 'package:flutter_test/flutter_test.dart';
|
|
import 'package:integration_test/integration_test.dart';
|
|
|
|
import 'package:alt_client/src/integrations/socket/alt_socket_client.dart';
|
|
import 'package:alt_client/src/integrations/socket/socket_endpoint.dart';
|
|
|
|
void main() {
|
|
IntegrationTestWidgetsFlutterBinding.ensureInitialized();
|
|
|
|
testWidgets('connects to configured ALT API and completes hello handshake', (
|
|
tester,
|
|
) async {
|
|
const endpoint = AltSocketEndpoint();
|
|
|
|
final client = await AltSocketClient.connect(endpoint);
|
|
addTearDown(client.close);
|
|
|
|
final response = await client.hello(timeout: const Duration(seconds: 5));
|
|
|
|
expect(response.serverName, equals('alt-api'));
|
|
expect(response.serverVersion, equals('dev'));
|
|
expect(response.altProtocolVersion, equals('alt.v1'));
|
|
expect(response.capabilities, contains('hello'));
|
|
expect(response.capabilities, contains('request-response'));
|
|
});
|
|
}
|