@Test
    public void detectsClosingUnopenedBlock() {
        RuntimeException e = Assertions.assertThrows(RuntimeException.class, () -> {
            new SimpleCodeWriter().write("${/bar}");
        });

        assertThat(e.getMessage(), containsString("Attempted to close unopened tag: 'bar'"));
    }
\n"
                                + " * Foo \"foo!\"\n"
                                + " *\n"
                                + " * \"baz\"!\n"
                                + " * Yap!\n"
                                + " *     This is indented, in flow of parent.\n"
                                + " *     Yap!\n"
                                + " *     Yap?\n"
                                + " *     # Has a prefix\n"
                                + " *     # Yes\n"
                                + "
smithy-utils/src/test/java/software/amazon/smithy/utils/CodeWriterTest.java