aboutsummaryrefslogtreecommitdiff
path: root/test/org/traccar/protocol/MegastekProtocolDecoderTest.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2013-11-09 19:01:19 +1300
committerAnton Tananaev <anton.tananaev@gmail.com>2013-11-09 19:01:19 +1300
commitcf0565caceee6856328e481dd23600ed2590c88a (patch)
tree9d2cc8cf8d3eb27b36412eb492ad702581891f1c /test/org/traccar/protocol/MegastekProtocolDecoderTest.java
parentf9ecee5b732b0c82c8a95bebdb5e275ea479cccc (diff)
downloadtrackermap-server-cf0565caceee6856328e481dd23600ed2590c88a.tar.gz
trackermap-server-cf0565caceee6856328e481dd23600ed2590c88a.tar.bz2
trackermap-server-cf0565caceee6856328e481dd23600ed2590c88a.zip
Improve unit test verification
Diffstat (limited to 'test/org/traccar/protocol/MegastekProtocolDecoderTest.java')
-rw-r--r--test/org/traccar/protocol/MegastekProtocolDecoderTest.java15
1 files changed, 8 insertions, 7 deletions
diff --git a/test/org/traccar/protocol/MegastekProtocolDecoderTest.java b/test/org/traccar/protocol/MegastekProtocolDecoderTest.java
index d1cb945a6..a157f01c0 100644
--- a/test/org/traccar/protocol/MegastekProtocolDecoderTest.java
+++ b/test/org/traccar/protocol/MegastekProtocolDecoderTest.java
@@ -1,6 +1,7 @@
package org.traccar.protocol;
-import static org.junit.Assert.assertNotNull;
+import org.traccar.helper.TestDataManager;
+import static org.traccar.helper.DecoderVerifier.verify;
import org.junit.Test;
public class MegastekProtocolDecoderTest {
@@ -11,22 +12,22 @@ public class MegastekProtocolDecoderTest {
MegastekProtocolDecoder decoder = new MegastekProtocolDecoder(null);
decoder.setDataManager(new TestDataManager());
- assertNotNull(decoder.decode(null, null,
+ verify(decoder.decode(null, null,
"STX,GerAL22,$GPRMC,174752.000,A,3637.060059,S,6416.2354,W,0.00,0.00,030812,,,A*55,F,,imei:861785000249353,05,180.6,Battery=100%,,1,722,310,0FA6,39D0;8F"));
- assertNotNull(decoder.decode(null, null,
+ verify(decoder.decode(null, null,
"STX,GerAL22,$GPRMC,000051.000,A,3637.079590,S,6416.2148,W,1.72,332.98,010109,,,A*52,L,,imei:861785000249353,03,275.3,Battery=68%,,1,722,07,0515,1413;41"));
- assertNotNull(decoder.decode(null, null,
+ verify(decoder.decode(null, null,
"STX,102110830074542,$GPRMC,114229.000,A,2238.2024,N,11401.9619,E,0.00,0.00,310811,,,A*64,F,LowBattery,imei:012207005553885,03,113.1,Battery=24%,,1,460,01,2531,647E;57"));
- assertNotNull(decoder.decode(null, null,
+ verify(decoder.decode(null, null,
"STX863070014949464 $GPRMC,215942.290,A,4200.1831,N,02128.5904,E,003.1,079.8,090813,,,A*6E,294,02,0064,0F3D,18,17,0000,000000,0000,0.00,0.02,0.00,Store;D8"));
- assertNotNull(decoder.decode(null, null,
+ verify(decoder.decode(null, null,
"STX123456 $GPRMC,063709.000,A,2238.1998,N,11401.9670,E,0.00,,250313,,,A*7F,460,01,2531,647E,11,87,1000,001001,0000,0.00,0.02,0.00,Timer;4A"));
- assertNotNull(decoder.decode(null, null,
+ verify(decoder.decode(null, null,
"STX260475 $GPRMC,104032.001,A,4022.1119,N,01811.4081,E,000.0,000.0,060913,,,A*67,222,01,815A,D455,11,99,0000,0001,0,Timer;"));
}