mirror of
https://github.com/dotnet/MQTTnet.git
synced 2026-10-23 13:23:05 +08:00
Refactor web socket usage
This commit is contained in:
@@ -394,7 +394,7 @@ namespace MQTTnet.Core.Tests
|
||||
|
||||
public Stream ReceiveStream => _stream;
|
||||
|
||||
public Stream RawStream => _stream;
|
||||
public Stream RawReceiveStream => _stream;
|
||||
|
||||
public Stream SendStream => _stream;
|
||||
|
||||
|
||||
@@ -18,12 +18,12 @@ namespace MQTTnet.Core.Tests
|
||||
|
||||
public IMqttPacketSerializer PacketSerializer { get; } = new MqttPacketSerializer();
|
||||
|
||||
public Task ConnectAsync(MqttClientOptions options, TimeSpan timeout)
|
||||
public Task ConnectAsync(TimeSpan timeout, MqttClientOptions options)
|
||||
{
|
||||
return Task.FromResult(0);
|
||||
}
|
||||
|
||||
public Task DisconnectAsync()
|
||||
public Task DisconnectAsync(TimeSpan timeout)
|
||||
{
|
||||
return Task.FromResult(0);
|
||||
}
|
||||
@@ -47,7 +47,7 @@ namespace MQTTnet.Core.Tests
|
||||
return Task.Run(() => _incomingPackets.Take());
|
||||
}
|
||||
|
||||
public IEnumerable<MqttBasePacket> ReceivePackets( CancellationToken cancellationToken )
|
||||
public IEnumerable<MqttBasePacket> ReceivePackets(CancellationToken cancellationToken)
|
||||
{
|
||||
return _incomingPackets.GetConsumingEnumerable();
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user