@DisplayName("from returns IllegalArgumentException if error frame has illegal error code")
@Test
void fromIllegalErrorFrame() {

  ByteBuf byteBuf = createErrorFrame(0, 0x00000000, "test-message");
  assertThat(Exceptions.from(0, byteBuf))
      .hasMessage("Invalid Error frame in Stream ID 0: 0x%08X '%s'", 0, "test-message")
      .isInstanceOf(IllegalArgumentException.class);
  assertThat(Exceptions.from(1, byteBuf))
      .hasMessage("Invalid Error frame in Stream ID 1: 0x%08X '%s'", 0x00000000, "test-message")
      .isInstanceOf(IllegalArgumentException.class);
}