@Test
public void literalsMustNotContainTrailingOpenBrace() {

    Throwable thrown = Assertions.assertThrows(InvalidPatternException.class, () -> {
        EndpointTrait.builder()
                .hostPrefix("foo-{")
                .build();
    });
    assertThat(thrown.getMessage(), containsString("Unclosed label found in pattern"));
}