aboutsummaryrefslogtreecommitdiff
path: root/test/org/traccar/protocol/Tr20ProtocolDecoderTest.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2012-11-13 21:58:17 +1300
committerAnton Tananaev <anton.tananaev@gmail.com>2012-11-13 21:58:17 +1300
commit3ee4d2fba538eee4d1774bd79e07c64dc0af97e5 (patch)
treeaaf69aa6b63874ccb226f966b2681746eee28a65 /test/org/traccar/protocol/Tr20ProtocolDecoderTest.java
parentf0d4f9de581b1f579608cbc3f5165c0b14317993 (diff)
downloadtrackermap-server-3ee4d2fba538eee4d1774bd79e07c64dc0af97e5.tar.gz
trackermap-server-3ee4d2fba538eee4d1774bd79e07c64dc0af97e5.tar.bz2
trackermap-server-3ee4d2fba538eee4d1774bd79e07c64dc0af97e5.zip
Added TR20 support (Fix #79)
Diffstat (limited to 'test/org/traccar/protocol/Tr20ProtocolDecoderTest.java')
-rw-r--r--test/org/traccar/protocol/Tr20ProtocolDecoderTest.java21
1 files changed, 21 insertions, 0 deletions
diff --git a/test/org/traccar/protocol/Tr20ProtocolDecoderTest.java b/test/org/traccar/protocol/Tr20ProtocolDecoderTest.java
new file mode 100644
index 000000000..aa978655b
--- /dev/null
+++ b/test/org/traccar/protocol/Tr20ProtocolDecoderTest.java
@@ -0,0 +1,21 @@
+package org.traccar.protocol;
+
+import static org.junit.Assert.assertNotNull;
+import static org.junit.Assert.assertNull;
+import org.junit.Test;
+
+public class Tr20ProtocolDecoderTest {
+
+ @Test
+ public void testDecode() throws Exception {
+
+ Tr20ProtocolDecoder decoder = new Tr20ProtocolDecoder(new TestDataManager());
+
+ assertNull(decoder.decode(null, null, "%%TRACKPRO01,1"));
+
+ assertNotNull(decoder.decode(null, null,
+ "%%TR-10,A,050916070549,N2240.8887E11359.2994,0,000,NA,D3800000,150,CFG:resend|"));
+
+ }
+
+}