public async Task TestConnect()
 {
     _mockSdk.Setup(m => m.InitializeSerialPort(It.IsAny <string>(), It.IsAny <object>(), It.IsAny <int>()))
     .Returns(Task.FromResult(true));
     _mockSdk.Setup(m => m.SendCommand <StateResponse>(It.IsAny <StateCommand>()))
     .Returns(Task.FromResult(new StateResponse {
         DeviceResponse = "*S99000"
     }));
     _mockSdk.Setup(m => m.SendCommand <FirmwareVersionResponse>(It.IsAny <FirmwareVersionCommand>()))
     .Returns(Task.FromResult(new FirmwareVersionResponse {
         DeviceResponse = "*V99124"
     }));
     Assert.That(await _sut.Connect(It.IsAny <CancellationToken>()), Is.True);
 }
 public async Task TestCoverState(CoverState coverState, string deviceResponse)
 {
     Assert.That(await _sut.Connect(new CancellationToken()), Is.True);
     _mockSdk.Setup(m => m.SendCommand <StateResponse>(It.IsAny <StateCommand>()))
     .Returns(Task.FromResult(new StateResponse {
         DeviceResponse = deviceResponse
     }));
     Assert.That(_sut.CoverState, Is.EqualTo(coverState));
 }