aboutsummaryrefslogtreecommitdiff
path: root/src/test/java/org/traccar/protocol
diff options
context:
space:
mode:
authorAnton Tananaev <anton@traccar.org>2022-08-08 17:47:25 -0700
committerAnton Tananaev <anton@traccar.org>2022-08-08 17:47:25 -0700
commit8fb2596c60d8e63e9933de4b077253f14daa1472 (patch)
treeba16ac044e6393f7d7f7500b4d1641630b81fa53 /src/test/java/org/traccar/protocol
parenta551ac40761520e8d48e4438213f70854569c1d9 (diff)
downloadtrackermap-server-8fb2596c60d8e63e9933de4b077253f14daa1472.tar.gz
trackermap-server-8fb2596c60d8e63e9933de4b077253f14daa1472.tar.bz2
trackermap-server-8fb2596c60d8e63e9933de4b077253f14daa1472.zip
Implement BSTPL protocol
Diffstat (limited to 'src/test/java/org/traccar/protocol')
-rw-r--r--src/test/java/org/traccar/protocol/BstplProtocolDecoderTest.java21
1 files changed, 21 insertions, 0 deletions
diff --git a/src/test/java/org/traccar/protocol/BstplProtocolDecoderTest.java b/src/test/java/org/traccar/protocol/BstplProtocolDecoderTest.java
new file mode 100644
index 000000000..ae4c47229
--- /dev/null
+++ b/src/test/java/org/traccar/protocol/BstplProtocolDecoderTest.java
@@ -0,0 +1,21 @@
+package org.traccar.protocol;
+
+import org.junit.Test;
+import org.traccar.ProtocolTest;
+
+public class BstplProtocolDecoderTest extends ProtocolTest {
+
+ @Test
+ public void testDecode() throws Exception {
+
+ var decoder = inject(new BstplProtocolDecoder(null));
+
+ verifyPosition(decoder, text(
+ "BSTPL$1,869630054439504,V,200722,045113,00.000000,0,00.00000,0,0,0,000,00,0,17,1,1,0,0,00.01,0,04.19,15B_190821,8991000907387031196F,12.27"));
+
+ verifyPosition(decoder, text(
+ "BSTPL$1,AP12AP3456,A,130720,160552,27.244183,N,83.673973,E,20,156,183,17,0,11,1,0,0,0,00.00,00,04.16,15_V1_0_0,89917380578146790443,12.16"));
+
+ }
+
+}