diff options
author | Anton Tananaev <anton.tananaev@gmail.com> | 2020-11-22 16:41:39 -0800 |
---|---|---|
committer | Anton Tananaev <anton.tananaev@gmail.com> | 2020-11-22 16:41:39 -0800 |
commit | cdf892cd39c528929284728562beef3220e91cf3 (patch) | |
tree | 4b83c071c7299501713a0e9309a4df5be4a22d00 /src/test | |
parent | 13801af75e4b8d2554f753b1d2cc1dafc89fd8c6 (diff) | |
download | traccar-server-cdf892cd39c528929284728562beef3220e91cf3.tar.gz traccar-server-cdf892cd39c528929284728562beef3220e91cf3.tar.bz2 traccar-server-cdf892cd39c528929284728562beef3220e91cf3.zip |
Decode fault codes
Diffstat (limited to 'src/test')
-rw-r--r-- | src/test/java/org/traccar/protocol/HuaShengProtocolDecoderTest.java | 4 | ||||
-rw-r--r-- | src/test/java/org/traccar/protocol/KhdProtocolDecoderTest.java | 3 |
2 files changed, 7 insertions, 0 deletions
diff --git a/src/test/java/org/traccar/protocol/HuaShengProtocolDecoderTest.java b/src/test/java/org/traccar/protocol/HuaShengProtocolDecoderTest.java index 9ba31e08a..7348ec547 100644 --- a/src/test/java/org/traccar/protocol/HuaShengProtocolDecoderTest.java +++ b/src/test/java/org/traccar/protocol/HuaShengProtocolDecoderTest.java @@ -18,6 +18,10 @@ public class HuaShengProtocolDecoderTest extends ProtocolTest { "c000000077aa0200000000000e000100143347315f48312e315f56312e30372e54000300133335353835353035303434303635380004000b3531323030303000050005010006000400070004000800050000090018383936313032353431343533333239313833360d000a000f796573696e7465726e6574c0")); verifyAttribute(decoder, binary( + "C00000001CAA120000000000020001001001000200030043008200C100C0"), + Position.KEY_DTCS, "P0100 P0200 P0300 C0300 B0200 U0100"); + + verifyAttribute(decoder, binary( "c000000049aa0000000000028e8800000032303038323630373534323800e1d47fffcd163d0000000000f30000000100157703f8000046000000000aade0ffffffff0011000800000496c0"), Position.KEY_HOURS, 58.7); diff --git a/src/test/java/org/traccar/protocol/KhdProtocolDecoderTest.java b/src/test/java/org/traccar/protocol/KhdProtocolDecoderTest.java index 62b6070b6..aa80c1cd9 100644 --- a/src/test/java/org/traccar/protocol/KhdProtocolDecoderTest.java +++ b/src/test/java/org/traccar/protocol/KhdProtocolDecoderTest.java @@ -10,6 +10,9 @@ public class KhdProtocolDecoderTest extends ProtocolTest { KhdProtocolDecoder decoder = new KhdProtocolDecoder(null); + verifyPosition(decoder, binary( + "2929a3003420b2ab46201115115601800115110350825100000133fb00df4bfdff0d000000000000000900000c180887d9ffffffffffff960d")); + verifyNull(decoder, binary( "2929b1000605162935b80d")); |