aboutsummaryrefslogtreecommitdiff
path: root/test/org/traccar/protocol/VisiontekProtocolDecoderTest.java
diff options
context:
space:
mode:
authorAnton Tananaev <anton.tananaev@gmail.com>2015-10-22 15:26:17 +1300
committerAnton Tananaev <anton.tananaev@gmail.com>2015-10-22 15:26:17 +1300
commit1ca95d099df96d576a0eaddc6e42b5b41aed3e06 (patch)
tree65ae84eb5e301317263fd72c31cc54922c71eb96 /test/org/traccar/protocol/VisiontekProtocolDecoderTest.java
parent122a26d2822f35b27b9cb0b217916d6b821d9654 (diff)
downloadtrackermap-server-1ca95d099df96d576a0eaddc6e42b5b41aed3e06.tar.gz
trackermap-server-1ca95d099df96d576a0eaddc6e42b5b41aed3e06.tar.bz2
trackermap-server-1ca95d099df96d576a0eaddc6e42b5b41aed3e06.zip
Refactor protocol unit testing
Diffstat (limited to 'test/org/traccar/protocol/VisiontekProtocolDecoderTest.java')
-rw-r--r--test/org/traccar/protocol/VisiontekProtocolDecoderTest.java13
1 files changed, 6 insertions, 7 deletions
diff --git a/test/org/traccar/protocol/VisiontekProtocolDecoderTest.java b/test/org/traccar/protocol/VisiontekProtocolDecoderTest.java
index 5d1879193..ad637256e 100644
--- a/test/org/traccar/protocol/VisiontekProtocolDecoderTest.java
+++ b/test/org/traccar/protocol/VisiontekProtocolDecoderTest.java
@@ -1,8 +1,7 @@
package org.traccar.protocol;
-import static org.junit.Assert.assertNull;
import org.junit.Test;
-import static org.traccar.helper.DecoderVerifier.verify;
+import org.traccar.ProtocolDecoderTest;
public class VisiontekProtocolDecoderTest extends ProtocolDecoderTest {
@@ -11,19 +10,19 @@ public class VisiontekProtocolDecoderTest extends ProtocolDecoderTest {
VisiontekProtocolDecoder decoder = new VisiontekProtocolDecoder(new VisiontekProtocol());
- //verify(decoder.decode(null, null,
+ //verifyPosition(decoder, text(
// "$1,AP116,05,06,15,11,48,32,1725.0460N,07824.5289E,0617,07,0,030,2091,0,0,0,1,1,1,1,20,00.0000,00.3820,00.0000,VAJRA V1.00,A#"));
- verify(decoder.decode(null, null,
+ verifyPosition(decoder, text(
"$1,AP09BU9397,861785006462448,20,06,14,15,03,28,17267339N,078279407E,060.0,073,0550,11,0,1,0,0,1,1,26,A,0000000000"));
- assertNull(decoder.decode(null, null,
+ verifyNothing(decoder, text(
"$1,AP09BU9397,861785006462448,20,06,14,15,03,28,000000000,0000000000,000.0,000,0000,00,0,1,0,0,1,1,24,V,0000000000"));
- assertNull(decoder.decode(null, null,
+ verifyNothing(decoder, text(
"$1,1234567890,02,06,11,17,07,45,00000000,000000000,00.0,0,0,V"));
- verify(decoder.decode(null, null,
+ verifyPosition(decoder, text(
"$1,1234567890,02,06,11,17,07,45,17267690N,078279340E,060.0,113,0,A"));
}