WebSocketConfig.testing constructor

const WebSocketConfig.testing({
  1. required String url,
  2. Map<String, String> headers = const {},
  3. List<String> protocols = const [],
})

Creates a WebSocketConfig with minimal settings for testing.

Implementation

const WebSocketConfig.testing({
  required this.url,
  this.headers = const {},
  this.protocols = const [],
})  : connectionTimeout = const Duration(seconds: 5),
      enableReconnection = false,
      maxReconnectionAttempts = 0,
      initialReconnectionDelay = Duration.zero,
      maxReconnectionDelay = Duration.zero,
      backoffMultiplier = 1.0,
      enableMessageQueue = false,
      maxQueueSize = 0,
      heartbeatInterval = Duration.zero,
      enableHeartbeat = false,
      enableCompression = false;