public void EncodeMessage_NoCommandDataValidFalse_ByteArray()
        {
            ProtocolMessage msg = new ProtocolMessage(0x01, 0x84, Command.QueryRegister);

            byte[] output = MessageCodec.EncodeMessage(msg);
            byte   crc    = output[output.Length - 2];

            Assert.AreEqual(output[0], STX);
            Assert.AreEqual(output[1], msg.ControllerID);
            Assert.AreEqual(output[2], msg.MsgID);
            Assert.AreEqual(output[3], (byte)msg.Command);
            Assert.AreEqual(output[output.Length - 1], ETX);
            Assert.IsTrue(string.IsNullOrEmpty(MessageCodec.ValidateMessageBytes(output)));

            output[0] = 0x00;
            output[output.Length - 2] = 0x00;
            output[output.Length - 1] = 0x00;
            Assert.AreEqual(crc, MessageCodec.CalculateCRC(output));
        }