diff options
Diffstat (limited to 'test/org/traccar/protocol/MxtProtocolDecoderTest.java')
-rw-r--r-- | test/org/traccar/protocol/MxtProtocolDecoderTest.java | 38 |
1 files changed, 19 insertions, 19 deletions
diff --git a/test/org/traccar/protocol/MxtProtocolDecoderTest.java b/test/org/traccar/protocol/MxtProtocolDecoderTest.java index 07e27927e..454e57087 100644 --- a/test/org/traccar/protocol/MxtProtocolDecoderTest.java +++ b/test/org/traccar/protocol/MxtProtocolDecoderTest.java @@ -3,8 +3,8 @@ package org.traccar.protocol; import java.nio.ByteOrder; import org.jboss.netty.buffer.ChannelBuffers; import org.junit.Test; +import org.traccar.ProtocolDecoderTest; import org.traccar.helper.ChannelBufferTools; -import static org.traccar.helper.DecoderVerifier.verify; public class MxtProtocolDecoderTest extends ProtocolDecoderTest { @@ -13,32 +13,32 @@ public class MxtProtocolDecoderTest extends ProtocolDecoderTest { MxtProtocolDecoder decoder = new MxtProtocolDecoder(new MxtProtocol()); - verify(decoder.decode(null, null, ChannelBuffers.wrappedBuffer(ByteOrder.LITTLE_ENDIAN, ChannelBufferTools.convertHexString( - "01a631361e7a00082471418b052a2c46b587ffc01ae3fd000008800000000000003345422203000000f000f00000000000ea1e04")))); + verifyPosition(decoder, binary(ByteOrder.LITTLE_ENDIAN, + "01a631361e7a00082471418b052a2c46b587ffc01ae3fd000008800000000000003345422203000000f000f00000000000ea1e04")); - verify(decoder.decode(null, null, ChannelBuffers.wrappedBuffer(ByteOrder.LITTLE_ENDIAN, ChannelBufferTools.convertHexString( - "01a63118787d00086440628d226e2bc26a97feac8a3afd10210010308000000000000018003d2b10240000005e2f0000f427f21031feff0000593804")))); + verifyPosition(decoder, binary(ByteOrder.LITTLE_ENDIAN, + "01a63118787d00086440628d226e2bc26a97feac8a3afd10210010308000000000000018003d2b10240000005e2f0000f427f21031feff0000593804")); - verify(decoder.decode(null, null, ChannelBuffers.wrappedBuffer(ByteOrder.LITTLE_ENDIAN, ChannelBufferTools.convertHexString( - "01a631bd777d0008646e319e17292ce86798fed4cd3afd102110211030800000102403001f15003e2b102400000034300000f4271021007b175535a7be04")))); + verifyPosition(decoder, binary(ByteOrder.LITTLE_ENDIAN, + "01a631bd777d0008646e319e17292ce86798fed4cd3afd102110211030800000102403001f15003e2b102400000034300000f4271021007b175535a7be04")); - verify(decoder.decode(null, null, ChannelBuffers.wrappedBuffer(ByteOrder.LITTLE_ENDIAN, ChannelBufferTools.convertHexString( - "01a631e3f97e00087cf40a98151c2cc46898fee0ce3afd1021001030c0000006102116072e003829bb00000036102100001024000000062b0000f42730004b06a6384b4304")))); + verifyPosition(decoder, binary(ByteOrder.LITTLE_ENDIAN, + "01a631e3f97e00087cf40a98151c2cc46898fee0ce3afd1021001030c0000006102116072e003829bb00000036102100001024000000062b0000f42730004b06a6384b4304")); - verify(decoder.decode(null, null, ChannelBuffers.wrappedBuffer(ByteOrder.LITTLE_ENDIAN, ChannelBufferTools.convertHexString( - "01a63118787d00086468457a466a2bc26a97feac8a3afd10212010308000000000001fe1053d291024000000922f0000f4271021007b17553599bb04")))); + verifyPosition(decoder, binary(ByteOrder.LITTLE_ENDIAN, + "01a63118787d00086468457a466a2bc26a97feac8a3afd10212010308000000000001fe1053d291024000000922f0000f4271021007b17553599bb04")); - verify(decoder.decode(null, null, ChannelBuffers.wrappedBuffer(ByteOrder.LITTLE_ENDIAN, ChannelBufferTools.convertHexString( - "01a63118787d0008648645ec486a2bc26a97feac8a3afd1021001030c0000000001419eb05372b1024000000982a0000f4271021007b17000010308c04")))); + verifyPosition(decoder, binary(ByteOrder.LITTLE_ENDIAN, + "01a63118787d0008648645ec486a2bc26a97feac8a3afd1021001030c0000000001419eb05372b1024000000982a0000f4271021007b17000010308c04")); - verify(decoder.decode(null, null, ChannelBuffers.wrappedBuffer(ByteOrder.LITTLE_ENDIAN, ChannelBufferTools.convertHexString( - "01a631e3f97e00087cfa0af3151c2c126798febace3afd1021801030c0000006102122082f003e29bb00000037102100001024000000ab2f0000f42730004b060000488c04")))); + verifyPosition(decoder, binary(ByteOrder.LITTLE_ENDIAN, + "01a631e3f97e00087cfa0af3151c2c126798febace3afd1021801030c0000006102122082f003e29bb00000037102100001024000000ab2f0000f42730004b060000488c04")); - verify(decoder.decode(null, null, ChannelBuffers.wrappedBuffer(ByteOrder.LITTLE_ENDIAN, ChannelBufferTools.convertHexString( - "01a631e3f97e00087cfe0a4b161c2c126798febace3afd1021801030800000071021240731003e2abb00000038102100001024000000c12f0000f42730004b06a638633104")))); + verifyPosition(decoder, binary(ByteOrder.LITTLE_ENDIAN, + "01a631e3f97e00087cfe0a4b161c2c126798febace3afd1021801030800000071021240731003e2abb00000038102100001024000000c12f0000f42730004b06a638633104")); - verify(decoder.decode(null, null, ChannelBuffers.wrappedBuffer(ByteOrder.LITTLE_ENDIAN, ChannelBufferTools.convertHexString( - "01a63118787d0008648645ec486a2bc26a97feac8a3afd1021001030c0000000001419eb05372b1024000000982a0000f4271021007b17000010308c04")))); + verifyPosition(decoder, binary(ByteOrder.LITTLE_ENDIAN, + "01a63118787d0008648645ec486a2bc26a97feac8a3afd1021001030c0000000001419eb05372b1024000000982a0000f4271021007b17000010308c04")); } |