void () { String source = """ <user id="1"> <first_name>Max</first_name> <!-- asdf --> <last_name>Headroom</last_name> </user>"""; String pattern = "<first_name>$A$</first_name><last_name>$B$</last_name>"; assertEquals("find tag ignoring comments", 1, findMatchesCount(source, pattern, XmlFileType.INSTANCE)); }