diff options
Diffstat (limited to 'test/org/traccar/protocol/KhdProtocolEncoderTest.java')
-rw-r--r-- | test/org/traccar/protocol/KhdProtocolEncoderTest.java | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/test/org/traccar/protocol/KhdProtocolEncoderTest.java b/test/org/traccar/protocol/KhdProtocolEncoderTest.java index 872997d7f..2a3fb524b 100644 --- a/test/org/traccar/protocol/KhdProtocolEncoderTest.java +++ b/test/org/traccar/protocol/KhdProtocolEncoderTest.java @@ -6,6 +6,8 @@ import org.junit.Test; import org.traccar.helper.ChannelBufferTools; import org.traccar.model.Command; +import javax.xml.bind.DatatypeConverter; + public class KhdProtocolEncoderTest { @Test @@ -17,8 +19,8 @@ public class KhdProtocolEncoderTest { command.setDeviceId(1); command.setType(Command.TYPE_ENGINE_STOP); - Assert.assertEquals(encoder.encodeCommand(command), ChannelBuffers.wrappedBuffer(ChannelBufferTools.hexToBytes( - "2929390006000000003F0D"))); + Assert.assertEquals(encoder.encodeCommand(command), ChannelBuffers.wrappedBuffer( + DatatypeConverter.parseHexBinary("2929390006000000003F0D"))); } |