您最多选择25个主题 主题必须以字母或数字开头,可以包含连字符 (-),并且长度不得超过35个字符

MqttPacketSerializerTests.cs 615 B

6 年前
6 年前
6 年前
6 年前
6 年前
12345678910111213141516171819202122
  1. using Microsoft.VisualStudio.TestTools.UnitTesting;
  2. using MQTTnet.Formatter;
  3. using MQTTnet.Tests;
  4. namespace MQTTnet.AspNetCore.Tests
  5. {
  6. [TestClass]
  7. public class MqttPacketSerializerTestsWithSpanBasedReader : MqttPacketSerializer_Tests
  8. {
  9. protected override IMqttPacketBodyReader ReaderFactory(byte[] data)
  10. {
  11. var result = new SpanBasedMqttPacketBodyReader();
  12. result.SetBuffer(data);
  13. return result;
  14. }
  15. protected override IMqttPacketWriter WriterFactory()
  16. {
  17. return new SpanBasedMqttPacketWriter();
  18. }
  19. }
  20. }