@Test
void encodeUnsignedMediumLarge() {

  ByteBuf buffer = ByteBufAllocator.DEFAULT.buffer();
  NumberUtils.encodeUnsignedMedium(buffer, 0xFFFFFC);
  buffer.markReaderIndex();
  assertThat(buffer.readUnsignedMedium()).as("reading as unsigned medium").isEqualTo(16777212);
  buffer.resetReaderIndex();
  assertThat(buffer.readMedium()).as("reading as signed medium").isEqualTo(-4);
}