From 02c1fb78a8b1681325ec01f49ae6ff6603825243 Mon Sep 17 00:00:00 2001 From: Anton Tananaev Date: Thu, 26 Apr 2012 19:34:10 +0000 Subject: --- .../protocol/gps103/Gps103ProtocolDecoderTest.java | 49 ---------------------- 1 file changed, 49 deletions(-) delete mode 100644 test/org/traccar/protocol/gps103/Gps103ProtocolDecoderTest.java (limited to 'test/org/traccar/protocol/gps103/Gps103ProtocolDecoderTest.java') diff --git a/test/org/traccar/protocol/gps103/Gps103ProtocolDecoderTest.java b/test/org/traccar/protocol/gps103/Gps103ProtocolDecoderTest.java deleted file mode 100644 index 79ba76586..000000000 --- a/test/org/traccar/protocol/gps103/Gps103ProtocolDecoderTest.java +++ /dev/null @@ -1,49 +0,0 @@ -package org.traccar.protocol.gps103; - -import java.util.List; -import org.junit.Test; -import org.traccar.Device; -import org.traccar.Position; -import org.traccar.DataManager; -import static org.junit.Assert.*; - -public class Gps103ProtocolDecoderTest { - - private class TestDataManager implements DataManager { - public List getDevices() { - return null; - } - - public Device getDeviceByImei(String imei) { - Device device = new Device(); - device.setId(new Long(1)); - device.setImei("10000000000000"); - return device; - } - - public void setPosition(Position position) { - } - } - - @Test - public void testDecode() throws Exception { - - Gps103ProtocolDecoder decoder = new Gps103ProtocolDecoder(new TestDataManager(), 0); - - // assertNull(decoder.decode(null, null, "##,imei:10000000000000,A")); - - assertNotNull(decoder.decode(null, null, - "imei:10000000000000,help me,1004171910,,F,010203.000,A,0102.0003,N,00102.0003,E,1.02,")); - - assertNotNull(decoder.decode(null, null, - "imei:353451040164707,tracker,1105182344,+36304665439,F,214418.000,A,4804.2222,N,01916.7593,E,0.37,")); - - assertNotNull(decoder.decode(null, null, - "imei:353451042861763,tracker,1106132241,,F,144114.000,A,2301.9052,S,04909.3676,W,0.13,")); - - assertNotNull(decoder.decode(null, null, - "imei:359587010124900,tracker,0809231929,13554900601,F,112909.397,A,2234.4669,N,11354.3287,E,0.11,321.53,")); - - } - -} -- cgit v1.2.3