MySQLPacketCodecEngine implements DatabasePacketCodecEngine<MySQLPacket> { @Override public MySQLPacketPayload createPacketPayload(final ByteBuf message) { return new MySQLPacketPayload(message); }  @Override boolean isValidHeader(final int readableBytes); @Override void decode(final ChannelHandlerContext context, final ByteBuf in, final List<Object> out, final int readableBytes); @Override void encode(final ChannelHandlerContext context, final MySQLPacket message, final ByteBuf out); @Override MySQLPacketPayload createPacketPayload(final ByteBuf message);  }
@Test public void assertCreatePacketPayload() { assertThat(new MySQLPacketCodecEngine().createPacketPayload(byteBuf).getByteBuf(), is(byteBuf)); }