### Question:
AmqpJmsBytesMessageFacade extends AmqpJmsMessageFacade implements JmsBytesMessageFacade { @Override public boolean hasBody() { if (bytesOut != null) { return bytesOut.writtenBytes() > 0; } else { return getBinaryFromBody().getLength() != 0; } }  @Override AmqpJmsBytesMessageFacade copy(); @Override byte getJmsMsgType(); @Override void clearBody(); @Override InputStream getInputStream(); @Override OutputStream getOutputStream(); @Override void reset(); @Override int getBodyLength(); @Override boolean hasBody(); @Override JmsBytesMessage asJmsMessage(); @Override byte[] copyBody(); @Override void onSend(long producerTtl);  }### Answer:
@Test public void testHasBodyOnNewMessage() throws Exception { AmqpJmsBytesMessageFacade amqpBytesMessageFacade = createNewBytesMessageFacade(); assertFalse(amqpBytesMessageFacade.hasBody()); }
@Test public void testHasBodyWithContent() throws Exception { byte[] bodyBytes = "myOrigBytes".getBytes(); Message message = Message.Factory.create(); message.setBody(new Data(new Binary(bodyBytes))); AmqpJmsBytesMessageFacade amqpBytesMessageFacade = createReceivedBytesMessageFacade(createMockAmqpConsumer(), message); assertTrue(amqpBytesMessageFacade.hasBody()); }