aboutsummaryrefslogtreecommitdiff
path: root/src/test/java/org/traccar/protocol/TechTltProtocolDecoderTest.java
blob: 28a91709654f0ae9799adc4106672677b3b8d1b4 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
package org.traccar.protocol;

import org.junit.jupiter.api.Test;
import org.traccar.ProtocolTest;

public class TechTltProtocolDecoderTest extends ProtocolTest {

    @Test
    public void testDecode() throws Exception {

        var decoder = inject(new TechTltProtocolDecoder(null));

        verifyPosition(decoder, text(
                "002422269*POS=Y,16:21:20,25/11/09,3809.8063N,01444.7438E,4.17,117.23,0.4,09,40076,56341\r\n"),
                position("2009-11-25 16:21:20.000", true, 38.16344, 14.74573));

        verifyAttributes(decoder, text(
                "002422269,INFOGPRS,V Bat=13.8,TEMP=23,I TIM,15\r\n"));

    }

}