From cac617f6518ed5ad048cc9c57b80849c34650afa Mon Sep 17 00:00:00 2001 From: Oliver Schramm Date: Thu, 27 May 2021 15:28:16 +0200 Subject: Add unit test for alarm event decoding --- src/test/java/org/traccar/protocol/MegastekProtocolDecoderTest.java | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'src') diff --git a/src/test/java/org/traccar/protocol/MegastekProtocolDecoderTest.java b/src/test/java/org/traccar/protocol/MegastekProtocolDecoderTest.java index d2201a4a9..3747d9200 100644 --- a/src/test/java/org/traccar/protocol/MegastekProtocolDecoderTest.java +++ b/src/test/java/org/traccar/protocol/MegastekProtocolDecoderTest.java @@ -29,6 +29,10 @@ public class MegastekProtocolDecoderTest extends ProtocolTest { verifyNull(decoder, text( "0140$MGV002,354550056642321,GVT900-3,S,300917,071731,V,,,,,00,00,00,99.9,0.000,0.00,,0.0,457,01,0741,00CD,,0000,0000,20,10,0, , ,,1-1,94,PW ON;!")); + verifyAttribute(decoder, text( + "$MGV002,869152024446923,,S,290816,200627,V,5056.21059,N,00439.25034,E,00,00,00,99.9,,,-25.1,,206,01,0BBB,4418,28,,,,,,,,,01,093,PW ON;"), + Position.KEY_ALARM, Position.ALARM_POWER_ON); + verifyPosition(decoder, text( "$MGV002,869152024446923,,S,290816,200627,V,5056.21059,N,00439.25034,E,00,00,00,99.9,,,-25.1,,206,01,0BBB,4418,28,,,,,,,,,01,093,Timer;")); -- cgit v1.2.3