aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2015-10-05 22:43:55 +1300
committerAnton Tananaev <anton.tananaev@gmail.com>2015-10-05 22:43:55 +1300
commitca8264c895b67cb040b63604500254465abc7677 (patch)
tree2fc54af943d37bfff737f81ac99d2c7b1a9cd464 /test
parent037ff8b24880304190187a632612169c471a82a3 (diff)
downloadtrackermap-server-ca8264c895b67cb040b63604500254465abc7677.tar.gz
trackermap-server-ca8264c895b67cb040b63604500254465abc7677.tar.bz2
trackermap-server-ca8264c895b67cb040b63604500254465abc7677.zip
Handle H02 empty validity flag
Diffstat (limited to 'test')
-rw-r--r--test/org/traccar/protocol/H02ProtocolDecoderTest.java5
1 files changed, 4 insertions, 1 deletions
diff --git a/test/org/traccar/protocol/H02ProtocolDecoderTest.java b/test/org/traccar/protocol/H02ProtocolDecoderTest.java
index 744a9982d..076bdf65f 100644
--- a/test/org/traccar/protocol/H02ProtocolDecoderTest.java
+++ b/test/org/traccar/protocol/H02ProtocolDecoderTest.java
@@ -2,10 +2,10 @@ package org.traccar.protocol;
import java.nio.charset.Charset;
import org.jboss.netty.buffer.ChannelBuffers;
-import static org.traccar.helper.DecoderVerifier.verify;
import static org.junit.Assert.assertNull;
import org.junit.Test;
import org.traccar.helper.ChannelBufferTools;
+import static org.traccar.helper.DecoderVerifier.verify;
public class H02ProtocolDecoderTest extends ProtocolDecoderTest {
@@ -13,6 +13,9 @@ public class H02ProtocolDecoderTest extends ProtocolDecoderTest {
public void testDecode() throws Exception {
H02ProtocolDecoder decoder = new H02ProtocolDecoder(new H02Protocol());
+
+ verify(decoder.decode(null, null, ChannelBuffers.copiedBuffer(
+ "*HQ,355488020119695,V1,050418,,2827.61232,N,07703.84822,E,0.00,0,031015,FFFEFBFF#", Charset.defaultCharset())));
verify(decoder.decode(null, null, ChannelBuffers.copiedBuffer(
"*HQ,1451316409,V1,030149,A,-23-29.0095,S,-46-51.5852,W,2.4,065,070315,FFFFFFFF#", Charset.defaultCharset())));