void () { TextContent extracted = extractText("a.md", "* list [item](http://x) with a local link", 3); assertEquals("list item with a local link", unknownOffsets(extracted)); Assertions.assertArrayEquals(new int[]{"list ".length(), "list item".length()}, extracted.markupOffsets()); int prefix = "* ".length(); assertEquals(prefix + "list [".length(), extracted.textOffsetToFile("list ".length())); assertEquals(prefix + "list [item".length(), extracted.textOffsetToFile("list item".length())); }