@Test public void testCreateMessageString() { command = new TelemetryCommand(TelemetryRadioConstants.SET_RIT); command.addParameter(new TelemetryParameter("RIT", 0)); string.append("+J 0\n"); assertEquals(string.toString(), createMessage.createMessageString(command).toString()); }
public StringBuilder createMessageString(TelemetryCommand command) { StringBuilder messageString = new StringBuilder(); messageString.append("+A "); messageString.append(command.getParameter("Transceive")); messageString.append("\n"); return messageString; }