aboutsummaryrefslogtreecommitdiff
path: root/test/org/traccar/protocol/LaipacProtocolDecoderTest.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2014-06-25 20:45:52 +1200
committerAnton Tananaev <anton.tananaev@gmail.com>2014-06-25 20:45:52 +1200
commit19aa8eeb318dc9265e0b05d9cb1e4f1726a8e578 (patch)
treee70467349badca187e406f0ff36309eb8d2d8860 /test/org/traccar/protocol/LaipacProtocolDecoderTest.java
parent2b976dcce16f92b1e429906848f0ae70fcb05b54 (diff)
downloadtrackermap-server-19aa8eeb318dc9265e0b05d9cb1e4f1726a8e578.tar.gz
trackermap-server-19aa8eeb318dc9265e0b05d9cb1e4f1726a8e578.tar.bz2
trackermap-server-19aa8eeb318dc9265e0b05d9cb1e4f1726a8e578.zip
Fix Laipac protocol decoder
Diffstat (limited to 'test/org/traccar/protocol/LaipacProtocolDecoderTest.java')
-rw-r--r--test/org/traccar/protocol/LaipacProtocolDecoderTest.java36
1 files changed, 36 insertions, 0 deletions
diff --git a/test/org/traccar/protocol/LaipacProtocolDecoderTest.java b/test/org/traccar/protocol/LaipacProtocolDecoderTest.java
index f6bdf5d9e..4facc64fa 100644
--- a/test/org/traccar/protocol/LaipacProtocolDecoderTest.java
+++ b/test/org/traccar/protocol/LaipacProtocolDecoderTest.java
@@ -16,6 +16,12 @@ public class LaipacProtocolDecoderTest {
assertNull(decoder.decode(null, null, "$AVSYS,99999999,V1.50,SN0000103,32768*15"));
assertNull(decoder.decode(null, null, "$ECHK,99999999,0*35"));
+
+ assertNull(decoder.decode(null, null, "$AVSYS,MSG00002,14406,7046811160,64*1A"));
+
+ assertNull(decoder.decode(null, null, "$EAVSYS,MSG00002,8931086013104404999,,Owner,0x52014406*76"));
+
+ assertNull(decoder.decode(null, null, "$ECHK,MSG00002,0*5E"));
verify(decoder.decode(null, null,
"$AVRMC,99999999,164339,A,4351.0542,N,07923.5445,W,0.29,78.66,180703,0,3.727,17,1,0,0*37"));
@@ -44,6 +50,36 @@ public class LaipacProtocolDecoderTest {
verify(decoder.decode(null, null,
"$AVRMC,99999999,164339,A,4351.0542,N,07923.5445,W,0.29,78.66,180703,4,3.727,17,1,0,0*33"));
+ verify(decoder.decode(null, null,
+ "$AVRMC,MSG00002,003016,v,0000.0000,N,00000.0000,E,0.00,0.00,200614,0,3804,167,1,0,0,0D7AB913,020408*23"));
+
+ verify(decoder.decode(null, null,
+ "$AVRMC,MSG00002,003049,V,0000.0000,N,00000.0000,E,0.00,0.00,200614,H,3804,167,1,0,0,0D7AB913,020408*71"));
+
+ verify(decoder.decode(null, null,
+ "$AVRMC,MSG00002,041942,V,0000.0000,N,00000.0000,E,0.00,0.00,200614,H,4115,167,1,0,0*0E"));
+
+ verify(decoder.decode(null, null,
+ "$AVRMC,MSG00002,043703,V,0000.0000,N,00000.0000,E,0.00,0.00,200614,H,4115,167,1,0,0*07"));
+
+ verify(decoder.decode(null, null,
+ "$AVRMC,MSG00002,043750,V,0000.0000,N,00000.0000,E,0.00,0.00,200614,H,4115,167,1,0,0*01"));
+
+ verify(decoder.decode(null, null,
+ "$AVRMC,MSG00002,124022,V,0000.0000,N,00000.0000,E,0.00,0.00,240614,3,4076,167,1,0,0,0D7AB913,020408*0D"));
+
+ verify(decoder.decode(null, null,
+ "$AVRMC,MSG00002,124058,A,5053.0447,N,00557.8549,E,0.45,65.06,240614,0,4037,167,1,0,0,0D7AB913,020408*26"));
+
+ verify(decoder.decode(null, null,
+ "$AVRMC,MSG00002,124144,A,5053.0450,N,00557.8544,E,0.00,65.06,240614,3,4076,167,1,0,0,0D7AB913,020408*26"));
+
+ verify(decoder.decode(null, null,
+ "$AVRMC,MSG00002,125142,R,5053.0442,N,00557.8694,E,1.21,40.90,240614,0,4037,167,1,0,0,0D7AB913,020408*33"));
+
+ verify(decoder.decode(null, null,
+ "$AVRMC,MSG00002,125517,R,5053.0442,N,00557.8694,E,0.00,0.00,240614,H,4076,167,1,0,0,0D7AB913,020408*75"));
+
}
}